What is Robots.txt and Why Does It Matter?
Robots.txt is a simple text file located in the root directory of your website. This file instructs search engine crawlers (Google, Yandex, Bing) how to behave on your site. When crawlers visit your website and analyze pages, they check this file and only index what you allow. Many companies in Azerbaijan ignore this file, but incorrect configuration can significantly reduce your visibility in Google search results.
What Should You Block in Robots.txt?
You should not block all pages. Protect only the following:
- Admin panel: /admin, /wp-admin (on WordPress sites) — visitors should not see these
- Search result pages: /search/, /results/ — they create duplicate content
- Personal account pages: /profile/, /account/ — user panels do not help SEO
- Empty URL parameters: /product/?sort=price&filter=color — mobile versions and print pages
- Duplicate content: /print/, /pdf/, /mobile/ versions
- Error pages: /404/, /error/ — people don't want to see these
General rule: block pages that crawlers should not index, but always allow product pages, blog articles, and useful content.
How Should Robots.txt Be Written?
For most websites in Azerbaijan, a simple example is sufficient. Each line is a separate rule:
User-agent: * — this applies to all crawlers
Disallow: /admin — this protects a directory from crawlers
Allow: /admin/public — but allows this specific path
Crawl-delay: 2 — forces 2 seconds between crawler visits, reducing server load
Sitemap: https://example.com/sitemap.xml — tells Google about your site
Remember: robots.txt is not secure. Anyone can read it at /robots.txt. Never put secret information here.
Common Mistakes in Azerbaijan
These errors frequently occur on e-commerce sites:
- Blocking the entire site: "Disallow: /" — this prevents Google from seeing your site completely
- Incorrect wildcard rules: "Disallow: *.php" does not work. Use "Disallow: /*.php" instead
- Case sensitivity errors: "Disallow: /Admin" and "Disallow: /admin" block different paths
- Forgetting sitemap reference: Add "Sitemap: https://example.com/sitemap.xml" — Google will index your site faster
- File reset after hosting changes: When changing hosting, robots.txt may revert to the old version
Test Robots.txt in Google Search Console
After any changes, open Google Search Console (search.google.com) and use the Robots.txt Tester tool from the left menu. This tool shows syntax errors and simulates real crawler behavior. Enter a URL and click "TEST" — Google will tell you if this page is blocked or not.
Conclusion
Robots.txt is a powerful SEO tool, but it is often configured incorrectly. Configure it once after building your site, then check Google Search Console every few weeks. If there are errors, fix them. If you use Creative Group's hosting services, we can help with technical SEO configuration.