5

All the questions with similar titles are the inverse of what I want. I would like to connect my tablet (that is "blocked" on the Wifi) to my Windows 10 computer over a USB cable and have the computer "share" the Wifi. Is this possible?

EX: My tablet is blocked from the internet (home policy) but you can get Wifi by asking and staying in the main rooms, I want to have my tablet access the internet by having the computer "share" the internet with the tablet. I don't know if this is possible and if it is would like to know how.

I have a Nexus 7 2013 32GB Wifi on 6.0

3
  • I am trying to understand this: Your tablet doesn't have wifi you want to connect it to your computer via USB cable? Yes this is possible- normally when you attach your android device to PC it automatically installs MTP driver to enable you to browse the device folders. Secondly what programs which require admin rights are you trying to run ( I assume on your PC?) Do you wish to do file transfers of some sort between the 2 devices? Commented Mar 14, 2017 at 13:55
  • I thought I could comment on this before writing an answer to get clarity. You wish to share the internet from your computer over wifi because your tablet is blocked to access that particular wifi? . Short answer yes it is possible to share your wifi to give your tablet internet access, in this case there is no need for usb unless your pc doesn't have a wireless card in which case you need to perform what is called **reverse tethering Commented Mar 14, 2017 at 15:18
  • @xavier_fakerat yes pretty much, I think you understand, the nexus is blocked on the wifi (it can connect but the router will not let it access the internet)
    – user179568
    Commented Mar 14, 2017 at 15:59

1 Answer 1

9
+100

Different ways of sharing interet connection from Windows to other devices

Nowadays there is a lot of ways to share internet connection to other devices and each method has its pros and cons.

Here is a breakdown of methods:

  1. Using Windows 10 Mobile Hotspot Feature:

Windows 10 hotspot

Newer editions of windows 10 (after 1607 anniversary update) have a built in mobile hotspot feature which allows internet sharing to other devices

pros

  • easy to use as its built-in

  • no extra tools needed

  • internet is shared over Wi-Fi (no need for cables)

cons

  • some network types are not recognised e.g 3g dongles.

  1. Using 3rd party tools

    Nifty tools such as mhotspot, or Connectify provide the ability to share internet to other devices by making use of Microsoft Virtual Wi-Fi Adapters

pros

  • provide many additional tools to monitor and customising created networks

  • improved encryption

  • internet shared over Wi-Fi

cons

  • some of these are commercial softwares and are relatively expensive

Connectify


3a. USB Reverse tethering

Reverse tetherng is a relatively newer method of sharing internet especially from devices that do not have a wireless adapter. It uses the USB cable to share internet from the computer to the target device and oftern requires 3rd party tools and drivers as well as system modification of target devices.

  • Reverse Tethering (root) Requires the target devices to be rooted prior to connection and a USB server application or server to be installed on android. For better coverage this method often requires another Xposed module Hack connectivity service to increase internet coverage to most apps if not all.

    • Reverse tethering (no root) Similar to root based method but requires extra programs to be installed on windows

Specific requirements of reverse tethering no root:

pros - can provide faster connections usually with low latency - reverse tethering (no root) works on windows, linux and mac

cons

  • requires usb cable
  • installs additional apps on PC and phone
  • connections can be difficult to establish
  • some of these workarounds only work for some apps and not every app is guaranteed to have internet access, but from my experience browser, Gmail, google play were working just fine

Reverse tethering (root) interface


Update

3b. Using adb to reverse tether

Using bash script

alias t='r && sz $tether && r && sz $n'
tether='am start -n com.android.settings/com.android.settings.TetherSettings && input keyevent 66 && input keyevent 66'
n='netcfg rndis0 dhcp'
alias sz='ad shell'
alias de='ad devices -l'
alias r='ad kill-server && ad start-server'
alias ad='adb'
alias pu='adb push'

Special thanks to user42276 for this script

Pros

  • One good thing about scripting is that it eliminates the need for third party apps which may bloat the device/PC

Cons

  • Pretty much similar to method 3a above

  1. Using Windows ICS

Another way is to just use ICS in Windows with no third party software involved:

Requirements:

  • Terminal Emulator on your Android

  • Alternatively using adb shell commands (to use adb, you need to enable "USB debugging" on your Android).

  • Optional, BusyBox on your Android.

Instructions

  • Connect your Android to PC by USB cable and enable "USB tethering". You are still allowed to enable this option even when your 3g/wifi on your Android is off.
  • Windows will automatically search Windows Update and install driver for you.
  • Open "Network Connections" in Control Panel. Right click on an Internet connection that you have i.e WiFi connection (other connections like LAN also work), so right click on WLAN connection with Internet, and select "Properties".

    enter image description here

    • In tab "Sharing" click "Allow other network users to connect through...", then select the USB connection in dropdown list below.

enter image description here

  • Click OK. Windows will automatically setup your USB network connection and assign to it an IP address (usually 192.168.xxx.xxx or similar; for Win 7 and later its 192.168.137.1)
  • Your Internet connection is now "Shared" and your USB connection is now "Unidentified network".

Type the following command in Terminal Emulator:

netcfg rndis0 dhcp

The name for usb interface inside Android may vary. It is usually rndis0 or usb0. Type busybox ifconfig to identify the name.

It can happen that automatic dhcp method does not work. In this case we have to do it manually:

Type these following commands in Terminal Emulator:

ifconfig rndis0 192.168.137.2 netmask 255.255.2 route add default gw 192.168.137.1 dev rndis0

If route fails, try: busybox route add default gw 192.168.137.1 dev

Some applications (download in Google Play, Gmail, Facebook...) don't recognize the internet connection. You can try this way:

  • Enable temporarily 3G connection on your Android

  • Type: ifconfig rmnet0 0.0.0.0 The name for 3G interface inside Android may vary: ppp0, rmnet0... (Type busybox ifconfig to identify the name).

This will make applications see your Internet connection via USB as 3G/4G

Well its up to user to know which method suites them best. Hope it helps

4
  • Will possibly accept and give bounty once i try one and it works
    – user179568
    Commented Mar 14, 2017 at 16:23
  • Thank you please let me know if the method you chose works, I will be glad to assist further Commented Mar 14, 2017 at 16:29
  • @xaiver_fakerat yeah i chose the first one and it worked. I will give the bounty tomorrow (I can't award it for another 20 hours)
    – user179568
    Commented Mar 14, 2017 at 16:55
  • No problem @Down Christopher, I am glad I was able to assist you that's what matters to me Commented Mar 14, 2017 at 16:57

You must log in to answer this question.