• ARTICLES
SEARCH

How-To Geek

How to Activate VLC’s Web Interface, Control VLC From a Browser, & Use Any Smartphone as a Remote

image

VLC includes a web interface, which you can enable to access your VLC player from a web browser, controlling playback from another device – particularly useful for a media center PC. VLC also offers a mobile web interface for smartphones.

The web interface is turned off and locked down by default – you have to edit the web server’s .hosts file or VLC will disallow all incoming connections from other devices.

Activating the Web Interface

To activate the web interface, click the Tools menu in VLC and select Preferences.

image

Click the All option under Show settings to view VLC’s advanced settings. Scroll down in the list of advanced settings and select Main interfaces under the Interface header.

image

Click the Web check box to enable the HTTP interface.

image

Save your settings and restart VLC. Each time you start VLC, the web server will be started in the background – Windows will prompt you to allow VLC firewall access when you restart it, indicating that the web server is running.

image

Click the following link or plug its address into your browser to access the VLC web interface on your local computer: http://localhost:8080/

If you’re using VLC 2.0.1, certain elements of the web interface – the seek bar in particular — may not work properly. This is a bug in version 2.0.1  that isn’t present in 2.0.0 and has been fixed for version 2.0.2. VLC 2.0.0 includes a new web interface that replaces the old one – hopefully it will see more polish in future versions.

image

Allowing Remote Access

By default, the web interface is completely locked down – it’s restricted to localhost, which means you can only access it from the machine VLC is running on. You’ll see a 403 Forbidden error page if you try to access VLC’s HTTP server from any other device.

image

To allow access from other computers, you’ll have to edit the web interface’s .hosts file. You’ll find this file in different directories on different operating systems:

  • Windows – C:\Program Files (x86)\VideoLAN\VLC\lua\http (use “Program Files” instead of “Program Files (x86)” on 32-bit versions of Windows.)
  • Mac OS X – /Applications/VLC.app/Contents/MacOS/share/lua/http/.hosts
  • Linux – /usr/share/vlc/lua/http/.hosts

image

To edit this file on Windows, you’ll have to open Notepad – or another text editor – as Administrator. Browse to the folder mentioned above and select “All Files” in Notepad’s open dialog to view the .hosts file.

image

You can uncomment the last two lines (to uncomment a line, remove the # at the beginning of the line) to allow access from all IP addresses, but the file notes this isn’t completely safe. You could also allow a range of IP addresses – or specify the IP address of each other device you want to allow here (add each IP address on a separate line).

image

Save the file and restart VLC after making the change.

Using the Web Interface

Plug http://123.456.7.89:8080 into a web browser on an allowed computer or smartphone to view VLC’s web interface. Replace the “123.456.7.89” in the address with the IP address of the computer running VLC.

If you need to find your computer’s IP address, you can use the ipconfig command in a Command Prompt window. Look for the IPv4 Address row under the name of your connection.

image


If you also want to access VLC’s web interface over the Internet instead of your local network, you’ll have to forward ports on your router.

Chris Hoffman is a technology writer and all-around computer geek. He's as at home using the Linux terminal as he is digging into the Windows registry. Connect with him on Google+.

  • Published 06/23/12

Comments (8)

  1. Michael

    This is handy! I wish there was a mobile theme though – it would make it easier to control on my iPhone without having to zoom in all the time.

  2. Nathan J.

    At least on Android, there are a couple remote control apps that work over WiFi. Unified Remote is one. It requires a helper app to be installed, but that’s a lot easier than editing a .hosts file and enabling obscure settings and such. Hopefully with the impending release of VLC on Android, we’ll see some kind of official remote.

    That, or just get a wireless keyboard and/or mouse.

  3. Brett

    I have completed all the steps above including the .hosts file and I am still getting the 403 Forbidden error page.

    The following is what i have done to troubleshoot the problem
    - restarted vlc several times after I saved the changes to the .hosts file.
    - tried to access VLC’s HTTP server on the computer running vlc and on a computer outside my network.
    - read http://www.howtogeek.com/66214/how-to-forward-ports-on-your-router/
    - forwarded Port 8080 on my Router.

    Is there a way to change the port that vlc uses? What am I doing wrong?

  4. Michael

    @Nathan: do you have any idea why the web interface is mobile on Android, but not on the iPhone? The VLC website for this does state that 2.0 has a mobile web interface.

    Also, in regards to the wireless keyboard and mouse, I tried it once, got annoying when the batteries ran out in the middle of the night and I had none spare :P

  5. william

    lol…at your playlist….what is “nude” doing there? :P

  6. zef

    @william: this is a song by Radiohead

  7. ParalysedBeaver

    Is there any way to change the port that the web interface uses?

  8. LRC

    Seems nice, but there is no .hosts file in /usr/share/vlc/lua/http/ so I can’t possibly edit it.

Get Free Articles in Your Inbox!

Join 134,000 newsletter readers

Email:

Go check your email!