Link Safety

Disavow File Format Examples: Build a Valid .txt File

By BacklinkPrice Team · Dec 2, 2026 · 8 min read
Cover for Disavow File Format Examples: a document icon on a purple background

A disavow file is plain text with one URL or domain per line. These examples show domain entries, single URLs, comment lines, and the mistakes that break a file.

Quick answer: A disavow file is a text file with one URL or domain per line, saved as UTF-8 or 7-bit ASCII with a .txt name. Disavow a whole domain with a domain: prefix, disavow one page with its full URL, and add comment lines starting with a hash character. The file holds up to 100,000 lines and 2MB, with URLs up to 2,048 characters, according to Google's Search Console Help.

TL;DR: One entry per line, domain: for whole domains, full URL for single pages, hash character for comments. Keep the file plain text, under the size limits, and upload the full list every time.

Key takeaways

  • One URL or domain goes on each line, and you cannot disavow a subpath such as example.com/en/, according to Google's Search Console Help.
  • A domain: entry disavows the whole domain and every subdomain under it, including links added later.
  • A single URL entry disavows one page only, which suits a paid post on an otherwise real site.
  • Comment lines start with a hash character, and Google ignores them, so use them to record why each entry is there.
  • The file must be UTF-8 or 7-bit ASCII, named with a .txt ending, and no bigger than 100,000 lines and 2MB, according to Google's Search Console Help.
  • A new upload replaces the old list, so keep one master file and always upload the full version.

The rules every disavow file follows

Google's format rules are short, and every line of the file must follow them. According to Google's Search Console Help, you specify one URL or domain per line, and you cannot disavow an entire subpath, such as example.com/en/.

The file must be a text file encoded in UTF-8 or 7-bit ASCII, and the file name must end in .txt. According to Google's Search Console Help, the maximum URL length is 2,048 characters, and the maximum file size is 100,000 lines, including blank lines and comment lines, and 2MB.

Write the file in a plain text editor. According to GrowthScribe's 2026 guide, word processors add hidden formatting that breaks the file, and a file saved as .docx or .csv will not upload at all.

Domain entries: when one line covers a whole site

To disavow a domain or subdomain, prefix it with domain:, for example domain:example.com. According to Google's Search Console Help, that entry covers the domain and all of its subdomains, so one line can cover an entire network.

Use a domain entry when the whole site is the problem. A private blog network, a link farm, a hacked site, or a directory that exists only to sell links all qualify, because every page on the site is part of the same pattern.

A domain entry also covers links the site adds later. According to SerpSurfers' November 2026 guide, that forward cover is one reason to prefer domain entries for spam sites, since networks keep publishing new pages with the same links.

Single URL entries: one bad page on a real site

To disavow one page, write its full URL on its own line. According to Google's Search Console Help, the file format accepts a single URL when the site itself is fine but one page holds a link you want ignored.

Use a single URL when the site is real but one page is the problem, such as a sponsored post on a local blog or a comment thread on a forum. The rest of the site keeps its links, and only that page is set aside.

Do not list a folder or a section and expect Google to guess the rest. You cannot disavow a subpath, so list each bad URL on its own line, or disavow the whole domain when the bad pages keep multiplying.

Comment lines: document why each entry is there

Lines that begin with a hash character are comments, and Google ignores them. According to Google's Search Console Help, you can include comments if you like by starting a line with a hash mark, and any lines that begin with one are ignored.

Comments are where the file earns its keep. Note the reason for each entry, the date you added it, and whether you asked for removal first, so a future reader can tell a paid link from a hacked page without guessing.

Keep comments short and dated. According to AI Web Page SEO's 2026 disavow guide, a dated comment line such as a note on the month and the reason helps during a later review, when the file has grown to hundreds of lines and nobody remembers the first entries.

Three complete example files

The examples below use example domains, so copy the shape and not the entries. Each file is plain text, and each entry sits on its own line. Comment lines are shown in the Purpose column, since a comment line in the file itself starts with a hash character.

Example one is a small file for a paid-link cleanup, with two networks and two single pages:

LinePurpose
domain:paid-links-network.exampleA network of paid-link sites, removal requested twice
domain:cheap-guest-posts.exampleA guest post network, no reply to removal emails
https://blog.example/sponsored-reviewOne paid post on a real blog, owner would not edit
https://forum.example/thread-12345One comment-spam thread, site otherwise real

Example two is a file built after a manual action, with two network domains, one farm, and one paid article:

LinePurpose
domain:pbn-network-one.examplePrivate blog network found in the audit
domain:pbn-network-two.exampleSame network, second domain
domain:link-farm.exampleLink farm with thousands of outgoing links
https://news.example/paid-articlePaid article the owner would not remove

Example three is a file for a hacked-site cleanup, with one injected directory, one hacked post, and one comment network:

LinePurpose
domain:hacked-directory.exampleDirectory injected with spam links
https://blog.example/hacked-postOne hacked post on a real blog
domain:spam-comments.exampleComment spam network

Notice what the examples never do. No line holds two entries, no domain entry carries a trailing slash or a protocol, no wildcard appears, and no folder is listed as if it were a page. According to Google's Search Console Help, those are the exact mistakes that make a file invalid.

According to SerpSurfers' November 2026 guide, every rule in the disavow file comes from Google's disavow help page: one URL or domain per line, a domain: prefix for whole domains, UTF-8 or 7-bit ASCII encoding, a .txt name, up to 100,000 lines and 2MB, and URLs up to 2,048 characters long. Lines starting with a hash character are comments that Google ignores.

Common format errors the examples avoid

A trailing slash breaks a domain entry. According to AI Web Page SEO's 2026 disavow guide, domain:example.com/ is wrong, and the correct form is domain:example.com with nothing after the name.

A protocol breaks it too. According to the same guide, domain:https://example.com is wrong, because the domain entry takes a bare domain and nothing else.

Wildcards do not work. According to the same guide, domain:*.example.com is wrong, and plain domain:example.com already covers subdomains, so the wildcard adds nothing.

Two entries on one line break the file. Each line holds one directive, and a line with two URLs is read as one bad entry rather than two good ones.

Frequently Asked Questions

Can I disavow a whole folder of a site?

No. You cannot disavow a subpath such as example.com/en/. List the individual URLs, or disavow the whole domain with a domain: entry.

Do comment lines count toward the 100,000-line limit?

Yes. According to Google's Search Console Help, the maximum file size is 100,000 lines, including blank lines and comment lines, and 2MB. Keep comments short so they do not eat the budget.

Should I use domain entries or single URLs?

Use domain entries for sites that are spam throughout, and single URLs for one bad page on a real site. According to SerpSurfers' November 2026 guide, most real cases use domain entries, because spam sites publish the same link on many pages.

What encoding should the file use?

UTF-8 or 7-bit ASCII, saved as plain text with a .txt name. According to AI Web Page SEO's 2026 guide, save as UTF-8 without a byte order mark, since extra characters at the start of the file can break it.

Can I disavow a subdomain only?

Yes. A domain: entry for a subdomain, such as domain:spam.example.com, disavows that subdomain. According to Google's Search Console Help, prefixing a domain or subdomain with domain: covers it and everything under it.

Expert verdict

A disavow file is a small document with strict rules, and most failures come from the format rather than the decision. Get the syntax right once, keep one master file, and the upload step becomes routine.

Best for: anyone with a manual action who needs a file Google will accept on the first upload. Not for: anyone who wants to disavow a folder, a wildcard, or a list copied from a tool without reading it.

Treat the file as a record, not a one-off. Dated comments, a single master copy, and a quarterly review keep it honest, and an honest file is what a reviewer wants to see.

Learn what a disavow file is before you build one, so the format rules make sense.

Create a disavow file step by step, then check it against the examples above.

See an overview of the disavow tool to learn where the file goes once it is ready.

Check what the disavow tool is and when Google says to use it.

Find out when to disavow backlinks so the file lists links that actually need disavowing.

Check your backlinks free to see which domains link to your site before you write the file.

Bottom line

A valid disavow file is plain text with one URL or domain per line, domain: for whole domains, full URLs for single pages, and hash-character comments to record why each entry is there. According to Google's Search Console Help, stay inside the 100,000-line and 2MB limits, keep one master file, and upload the full list every time.

Sources

BacklinkPrice Team
Written by
BacklinkPrice Team
Link building and backlink pricing research

The BacklinkPrice Team researches backlink prices, publisher sites and link building tools. We check prices and plans against each provider's own pages and date them, so you know how current the numbers are.

More from BacklinkPrice Team

Related guides