Convert Figma logo to code with AI

badmojr logo1Hosts

Advanced DNS filter/blocklists for privacy, security, and clean browsing.

1,985
108
1,985
2

Top Related Projects

29,249

🔒 Consolidating and extending hosts files from several well-curated sources. Optionally pick extensions for porn, social media, and other categories.

8,504

AdAway is a free and open source ad blocker for Android.

Curated and well-maintained hostfile to block ads, tracking, cryptomining, and more! Updated regularly. ⚡🔒

2,742

Let's make an annoyance free, better open internet, altogether!

Automatically updated, moderated and optimized lists for blocking ads, trackers, malware and other garbage

Quick Overview

1Hosts is a curated collection of host files designed to block ads, trackers, and malware across various devices and platforms. It offers different filter levels and formats, allowing users to customize their ad-blocking experience based on their needs and preferences.

Pros

  • Comprehensive blocking of ads, trackers, and malware
  • Multiple filter levels (Lite, Pro, Xtra) for different user needs
  • Available in various formats (hosts, domains, adblock) for compatibility with different systems
  • Regular updates to maintain effectiveness against new threats

Cons

  • May occasionally block legitimate content, requiring manual whitelisting
  • Requires some technical knowledge to implement, especially on mobile devices
  • Potential performance impact on devices with limited resources
  • Not as user-friendly as browser-based ad-blocking extensions

Getting Started

To use 1Hosts:

  1. Choose the appropriate filter level (Lite, Pro, or Xtra) and format (hosts, domains, or adblock) from the repository.
  2. Download the chosen file or copy the raw URL.
  3. For hosts file method:
    • On Windows: Copy the file to C:\Windows\System32\drivers\etc\
    • On macOS/Linux: Copy the file to /etc/hosts
  4. For DNS-based blocking:
    • Configure your device or router to use a DNS service that supports custom blocklists (e.g., AdGuard DNS, NextDNS)
    • Add the raw URL of the chosen 1Hosts file to your DNS provider's blocklist
  5. For browser-based blocking:
    • Install an ad-blocking extension that supports custom filter lists (e.g., uBlock Origin)
    • Add the raw URL of the chosen 1Hosts file to your ad-blocker's custom filters

Note: Some methods may require administrative privileges or additional steps depending on your device and operating system.

Competitor Comparisons

29,249

🔒 Consolidating and extending hosts files from several well-curated sources. Optionally pick extensions for porn, social media, and other categories.

Pros of hosts

  • Larger community and more frequent updates
  • Offers multiple variants with different levels of blocking
  • Well-documented with clear instructions for various platforms

Cons of hosts

  • May be overly aggressive in blocking, potentially causing false positives
  • Less granular control over specific categories of blocked content
  • Larger file size, which may impact performance on some devices

Code Comparison

hosts:

0.0.0.0 example.com
0.0.0.0 ads.example.com
0.0.0.0 tracking.example.com

1Hosts:

0.0.0.0 example.com
0.0.0.0 ads.example.com
0.0.0.0 tracking.example.com

The basic structure of both hosts files is similar, using the 0.0.0.0 IP address to block domains. However, 1Hosts offers more specialized lists for different purposes, while hosts provides a more comprehensive, all-in-one approach.

Both projects aim to block unwanted content and improve privacy, but they differ in their approach and level of customization. hosts is more suitable for users who want a ready-to-use solution with minimal setup, while 1Hosts caters to those who prefer more control over their blocking lists and are willing to invest time in customization.

8,504

AdAway is a free and open source ad blocker for Android.

Pros of AdAway

  • Open-source Android app with a user-friendly interface for ad-blocking
  • Supports custom host sources and whitelist/blacklist functionality
  • Offers both root and non-root methods for ad-blocking

Cons of AdAway

  • Limited to Android devices, not a universal solution
  • Requires more user interaction and setup compared to 1Hosts
  • May impact battery life due to running as an app

Code Comparison

AdAway (Java):

private void applyHostsFile() {
    CommandResult result = Shell.SU.run(Constants.ANDROID_HOSTS_PATH);
    if (result.isSuccessful()) {
        // Hosts file applied successfully
    }
}

1Hosts (Hosts file format):

0.0.0.0 ad.example.com
0.0.0.0 tracker.example.com
0.0.0.0 analytics.example.com

While AdAway is an Android app with code for applying hosts files, 1Hosts is primarily a collection of curated hosts files. The code comparison shows the different approaches: AdAway programmatically applies hosts files, while 1Hosts provides ready-to-use hosts file content.

Pros of GoodbyeAds

  • More comprehensive blocking of ads and trackers in mobile apps
  • Includes specific lists for Samsung and Xiaomi devices
  • Regular updates and active community support

Cons of GoodbyeAds

  • May cause more false positives and break some legitimate services
  • Larger blocklist size, potentially impacting performance on low-end devices
  • Less granular control over blocked domains compared to 1Hosts

Code Comparison

1Hosts:

0.0.0.0 example-ad-domain.com
0.0.0.0 tracking-url.net

GoodbyeAds:

0.0.0.0 example-ad-domain.com
0.0.0.0 tracking-url.net
0.0.0.0 app-specific-ad.com
0.0.0.0 samsung-ads.com
0.0.0.0 xiaomi-tracking.net

Both repositories provide host files for ad and tracker blocking, but GoodbyeAds tends to include more mobile-specific and manufacturer-targeted entries. 1Hosts offers a more streamlined approach with fewer potential conflicts, while GoodbyeAds provides broader coverage at the cost of potential overblocking. Users should choose based on their specific needs and tolerance for potential false positives.

Curated and well-maintained hostfile to block ads, tracking, cryptomining, and more! Updated regularly. ⚡🔒

Pros of blacklist

  • More granular control with separate lists for different purposes (e.g., Facebook, porn, whitelist)
  • Includes a whitelist for commonly false-positive domains
  • Provides installation instructions for various platforms (Pi-hole, AdGuard Home, etc.)

Cons of blacklist

  • Less frequently updated compared to 1Hosts
  • Smaller overall blocklist size, potentially missing some domains
  • Lacks some advanced features like regex blocking

Code comparison

blacklist:

0.0.0.0 graph.facebook.com
0.0.0.0 pixel.facebook.com
0.0.0.0 an.facebook.com

1Hosts:

0.0.0.0 facebook.com
0.0.0.0 www.facebook.com
0.0.0.0 m.facebook.com

Key differences

  • Blocking approach: blacklist targets specific subdomains, while 1Hosts blocks entire domains
  • Update frequency: 1Hosts is updated more regularly
  • List organization: blacklist offers separate lists for different categories, 1Hosts provides unified lists with varying levels of protection

Recommendation

Choose blacklist if you need more fine-grained control and separate lists for different purposes. Opt for 1Hosts if you prefer a more comprehensive, frequently updated blocklist with simpler management.

2,742

Let's make an annoyance free, better open internet, altogether!

Pros of block

  • Offers multiple filter list variants for different use cases and device types
  • Regularly updated with community contributions and automated processes
  • Provides extensive documentation and usage instructions

Cons of block

  • Larger file sizes due to comprehensive blocking lists
  • May require more frequent updates to maintain effectiveness
  • Potentially higher risk of false positives due to extensive coverage

Code Comparison

block:

0.0.0.0 example.com
0.0.0.0 ads.example.com
0.0.0.0 tracking.example.com

1Hosts:

0.0.0.0 example.com
127.0.0.1 ads.example.com
::1 tracking.example.com

Key Differences

  1. List format: block uses consistent 0.0.0.0 for all entries, while 1Hosts varies between 0.0.0.0, 127.0.0.1, and ::1
  2. Scope: block offers more comprehensive coverage with multiple list variants, while 1Hosts focuses on a more curated approach
  3. Update frequency: block is updated more frequently, potentially providing better protection against new threats
  4. File size: 1Hosts tends to have smaller file sizes, which may be beneficial for devices with limited resources
  5. Customization: block provides more options for tailoring the blocking experience to specific needs, while 1Hosts offers a more streamlined approach

Both projects aim to enhance privacy and security by blocking unwanted domains, but they differ in their approach to list management, update frequency, and overall scope.

Automatically updated, moderated and optimized lists for blocking ads, trackers, malware and other garbage

Pros of hosts-blocklists

  • More comprehensive blocking lists, including additional categories like gambling and social media
  • Regular updates and active community contributions
  • Offers both domain-based and IP-based blocking options

Cons of hosts-blocklists

  • May cause over-blocking, potentially affecting legitimate services
  • Larger file size, which could impact performance on low-end devices
  • More complex setup and configuration process

Code Comparison

hosts-blocklists:

0.0.0.0 example-ad-domain.com
0.0.0.0 tracking-service.net
0.0.0.0 malware-site.org

1Hosts:

0.0.0.0 ad.example.com
0.0.0.0 analytics.tracker.com
0.0.0.0 malicious.domain.org

Both projects use similar syntax for blocking domains, with hosts-blocklists potentially including more diverse entries due to its broader scope.

Summary

hosts-blocklists offers a more extensive blocking solution with regular updates and community involvement, but may require more careful configuration to avoid over-blocking. 1Hosts provides a more streamlined approach, potentially sacrificing some coverage for ease of use and performance. The choice between the two depends on the user's specific needs and technical expertise.

Convert Figma logo designs to code with AI

Visual Copilot

Introducing Visual Copilot: A new AI model to turn Figma designs to high quality code using your components.

Try Visual Copilot

README

1Hosts

Safeguard your device(s) against pesky ads, trackers, and malware.

Last commit activity Repo size


1Hosts offers 2 blocklist variants tailored to different user needs:

🟢 1Hosts (Lite)

Balanced version - set & forget, prioritizes smooth UX, ideal for general users.
Client mirror 1 mirror 2 mirror 3
AdAway view view view
Pi-hole / OpenSnitch view view view
dnscrypt-proxy / personalDNSfilter / InviZible Pro dl view dl
uBlock Origin / AdGuardHome view view view
DNSCloak view view view
dnsmasq dl view view
Knot / Bind9 / PowerDNS view view view
Unbound dl view view
Windows dl view dl
Little Snitch dl view dl

🔴 1Hosts (Xtra) Beta

Aggressive version - maximum blocking against emerging privacy threats. May (occasionally) disrupt legit sites or services.

Available in all formats at releases.

Usage Notes

Choose between Lite and Xtra based on your needs, protection level, and tolerance for issues like false positives.

  • Lite
    For general users, beginners, families, or casual browsing where stability matters.
    Low false positives: Accurate, non-disruptive blocking.

  • Xtra
    Ideal for advanced users or privacy enthusiasts focused on maximum threat mitigation, even if it requires troubleshooting.
    However, it carries a higher false positive rate. This is an inherent trade-off for its aggressive nature, and users can report issues for removals. Not for everyone!

One easy trick is to use the "Lite" blocklist as your foundation, applied directly through a hosts file on your device.

This approach minimizes clutter in your DNS logs by handling basic blocking at the local level. Given that the Lite list is exceptionally accurate and reliable, it allows you to swiftly pinpoint any issues—since queries blocked via the hosts file are stopped before they ever hit your DNS resolver (e.g., NextDNS).


Add the appropriate URL to your adblock client's settings or use DNS options below.

ControlD: updates every 30 minutes; supports subdomain/wildcard & CNAME blocking; unlimited queries.

Name IPv4 IPv6 DNS-over-HTTPS DNS-over-TLS
1Hosts (Lite) 76.76.2.38 76.76.10.38 2606:1a40::38 2606:1a40:1::38 https://freedns.controld.com/x-1hosts-lite x-1hosts-lite.freedns.controld.com

nextDNS: updates every 30 minutes; customizable; supports subdomain/wildcard & CNAME blocking; capped at 300k queries per month (free); sign up required.
Click here.


AdGuard DNS: updates every hour; customizable; supports subdomain/wildcard & CNAME blocking; 30-day (unlimited) trial available, then capped at 300k queries per month (free); sign up required.
Click here.


RethinkDNS: updates infrequently; supports subdomain/wildcard & CNAME blocking; unlimited queries; open-source.

Name DNS-over-HTTPS DNS-over-TLS
1Hosts (Lite) https://max.rethinkdns.com/1:AAQCAA== 1-aacaeaa.max.rethinkdns.com


Compatible Software Suite


Why 1Hosts?

Highly effective, compact, and actively maintained (since: Dec 2, 2017). Smaller in size compared to alternatives, yet blocks more for many users.

⠀

Credits & ©:
To the curators whose diligence underpins this endeavor, thank you!


mentions
Config NextDNS
ControlD Setup
Wiki


Help us create a better experience <3!

  • ⭐ Star the repo.
  • Report false positives or issues via GitHub Issues.
  • Share with friends for a safer web.