TIP&HACK

How to Properly Upload the ads.txt File to Your WordPress Site

If you’re running AdSense or any other ad network on your WordPress site, you’ve probably seen a message saying something like:
“Earnings at risk – You need to fix some ads.txt file issues.”
Yup, it sounds serious — because it is! But don’t worry, uploading the ads.txt file correctly isn’t hard at all.
Let’s walk through how to do it properly, step by step 💡

advertisement

First, what is the ads.txt file?

“ads.txt” stands for Authorized Digital Sellers.
Think of it like a whitelist that tells the world:

“These are the only companies allowed to sell ads on my site.”

It helps protect your ad inventory from spoofing and ensures your revenue isn’t going to waste. That’s why platforms like AdSense require it.
So yes, this tiny file has a big job!

advertisement

Where exactly should you upload it?

Here’s the key point:
The ads.txt file must be placed in your website’s root directory.
In other words, when you type https://yourdomain.com/ads.txt in your browser, the file’s contents should appear right away.

Let’s break this down depending on where and how your WordPress is hosted.

1. For standard web hosting

When you connect to your server using FTP, you’ll likely see a folder named public_html, www, or html.
These are your root folders!
Upload your ads.txt file directly inside that folder — not inside any subfolders.

2. If you’re using a typical WordPress setup

Look for where your WordPress is installed.
If you see folders like wp-admin, wp-content, and wp-includes, that’s your root directory.
Just drop the ads.txt file right there!

3. Using AWS Lightsail with Bitnami?

Things are a bit more specific here.
Your WordPress root folder will be located at:
/opt/bitnami/apps/wordpress/htdocs
You’ll need SSH or SFTP access to get there, then place the ads.txt file in that directory.

advertisement

How to upload the file (3 easy ways)

Okay, now that we know where to put it, let’s go over how to get it there.

1. Using FTP/SFTP (like FileZilla)

This is one of the most straightforward ways.
Open FileZilla, connect using your FTP credentials, find the root folder (as explained above), and just drag-and-drop your ads.txt file in there!

2. Using your hosting provider’s File Manager

Many web hosts (like Bluehost, GoDaddy, Hostinger) provide a File Manager via cPanel.
You can log in to your hosting dashboard, open the File Manager, and upload the ads.txt file directly — no extra software needed.

3. Using a WordPress plugin

Don’t want to deal with FTP at all? No problem!
Install a plugin like Ads.txt Manager. It lets you add and edit your ads.txt content directly from your WordPress admin dashboard.
Just go to Settings > Ads.txt and paste in the ad network lines.

advertisement

How to check if it’s working

After uploading the file, test it by visiting:

arduino복사편집https://yourdomain.com/ads.txt

If you see your file’s contents appear in the browser, you’re all set! 🎉
If not, go back and double-check:

  • Is the file in the root folder?
  • Did you name it correctly as ads.txt?
  • Is there a redirect or caching plugin interfering?
advertisement

Common mistakes to avoid

Here are a few mistakes that trip people up:

  • ❌ Uploading ads.txt inside wp-content or wp-admin
  • ❌ Naming it ads.txt.txt or forgetting the .txt extension
  • ❌ Using subfolders like /blog/ads.txt (that won’t work!)
  • ❌ Editing the file in a word processor that adds extra formatting

Keep it simple — root folder, plain text, correct name.

advertisement

Quick Recap Table

Hosting Typeads.txt File Location
Shared Hostingpublic_html, www, or html
WordPress InstallWhere wp-admin, wp-content, wp-includes exist
AWS Lightsail/opt/bitnami/apps/wordpress/htdocs
Plugin MethodUse Ads.txt Manager plugin in WP admin
advertisement

Final Thoughts

Setting up ads.txt isn’t just a “nice-to-have” — it’s critical for your ad revenue.
The good news? Once you’ve uploaded it properly, you usually don’t have to touch it again unless your ad network info changes.
So invest 10–15 minutes now and save yourself from missing out on ad dollars later!

Copied title and URL