Windows 7 Forums

Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.

Windows 7: hosts file ! Safe to delete ?

16 Apr 2011   #11

Windows 7 Ultimate x64

Ok guys. I'll try to explain why do i want to delete this file
Some sites ( advertising, i guess ) are blocked in this file, manually. After i made this changes, i have some problems with "login" on some forums. Sounds wired, but it is so.
I don't know if it's allowed to say which sites i blocked, but some online newspapers are very very slow because of this sites. I'm not sure if it's advertisings, but anyway, they "block" some online newspapers.
I use Mozilla Firefox as default browser, but i tried Google Chrome / Opera / PaleMoon, and is the same story.

My System SpecsSystem Spec
16 Apr 2011   #12

Windows 10 Pro (x64)

Then just delete the entries you added. Why the need to delete the whole file........
My System SpecsSystem Spec
16 Apr 2011   #13

Windows 7 Ultimate x64

Ok, thanks, and sorry if a was a bit angry, earlier.
My System SpecsSystem Spec

16 Apr 2011   #14

Windows 7 Pro x64

This is what the file should look like.

# Copyright (c) 1993-2009 Microsoft Corp.
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding host name.
# The IP address and the host name should be separated by at least one
# space.
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a '#' symbol.
# For example:
# # source server
# # x client host

# localhost name resolution is handled within DNS itself.
# localhost
# ::1 localhost

Just copy and paste it into your hosts file opened in notepad. Save as all files with no extension.
My System SpecsSystem Spec
17 Apr 2011   #15
Bare Foot Kid
Microsoft MVP

W 7 64-bit Ultimate

Just for information sake, you have to open Notepad as an Administrator to be able to edit the Hosts file, I don't believe there has to be anything 'in' the Hosts file but I would not delete the file.

Hosts File : Use in Windows 7 / Vista
My System SpecsSystem Spec
17 Apr 2011   #16

Windows 7 Ultimate (x64)

I would be very surprised if the system still worked after the hosts file would be deleted.
My System SpecsSystem Spec
17 Apr 2011   #17

Windows 7 Pro x64

Quote   Quote: Originally Posted by unifex View Post
I would be very surprised if the system still worked after the hosts file would be deleted.
More then likely it would do 1 of 2 things.
1) Recreate that file.
2) Do nothing and not worry about it.

That file is there for the user to make changes to block or redirect certain IP addresses (at your choosing and discretion), whether local or public (internet). If it isn't there I don't think it would matter to the OS. As it is now it does not contain any info except on how configure/edit it, note the # in front of every line.
My System SpecsSystem Spec
17 Apr 2011   #18

Windows 7 x64 (RTM via MSDN)

Why not just try it. Rename hosts to hosts.old. Reboot and try to go online. If it fixes your problem, great, if not, rename hosts.old to hosts and reboot.
My System SpecsSystem Spec

 hosts file ! Safe to delete ?

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Similar help and support threads
Thread Forum
Hosts file ignored and replaced with hosts.original
Hello. I am trying to use the hosts file. However both pings and web addresses still bypass the hosts file. I noticed that there is another file in the C:\Windows\System32\drivers\etc directory called 'hosts.original'. When ever I delete this file, it reappears seconds later. I have made sure that...
General Discussion
Hosts File
Hey, I was wondering, is there any internet performance gain if you put a commonly used website's IP (like Google) in your Hosts file, so it doesn't need to ask a DNS server? I mean, because I have 30 websites I go on at least 10 times each day, and it lags when I open all of them :D Thanks!
General Discussion
Hosts file-S??
can the hosts file be changed to, or amended by, another file? IOW can there be a file named xyz that essentially replaces the hosts file, or adds entries to it? Possibly by a registry key or configuration setting? Of course it could by altering library fxns, but by other "simpler" means? ...
System Security
HOSTS File - Create a "Edit HOSTS file" Shortcut
How to Create a "Edit HOSTS file" Shortcut in Windows 7 and Vista The HOSTS file is a .txt file used in Vista and Windows 7 to map hostnames to IP addresses. Your computer checks this file first to resolve any network names to its corresponding IP address before it tries to check the Internet....
HOSTS file
I setup a hosts file in windows xp in order to use my website locally using the exact domain name by editing the hosts file by adding the line: This should resolve my local ip address for the site and if apache is running, then it should load the website...
Network & Sharing

Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 09:45.

Twitter Facebook Google+

Windows 7 Forums

Seven Forums Android App Seven Forums IOS App