Content Strategy & SEO

SXu
Participant | Platinum Partner
Participant | Platinum Partner

Baidu SEO included domain

SOLVE

I want Baidu browser to index the domain for SEO 

 

I added a code between the <head> tag and </head> tag of the HTML code, but the verification failed so far.

 

The reason for the failure is: the server has blocked Baidu's UA/IP.

 

Does anyone know how to unblock Baidu UA/IP from hubspot?

 

Thank you in advance for your support.

0 Upvotes
1 Accepted solution
himanshurauthan
Solution
Thought Leader | Elite Partner
Thought Leader | Elite Partner

Baidu SEO included domain

SOLVE

Hello @SXu 

If your server is blocking Baidu's User-Agent (UA) or IP address, you will need to modify your server's configuration to allow Baidu's UA/IP to access your site. This can be done by adding the UA/IP to your server's allowlist.

To do this, you will need to access your server's configuration files, which will vary depending on your hosting environment. If you are using a shared hosting environment, you may need to contact your hosting provider for assistance.

Once you have access to your server's configuration files, you can add the following lines of code to your .htaccess file to allowlist Baidu's UA/IP:

# allowlist Baidu UA/IP 
RewriteEngine On 
RewriteCond %{HTTP_USER_AGENT} "Baiduspider" [NC,OR] 
RewriteCond %{REMOTE_ADDR} ^123\.125\.71\. [OR] 
RewriteCond %{REMOTE_ADDR} ^220\.181\.108\. [OR] 
RewriteCond %{REMOTE_ADDR} ^180\.76\.[0-9]+\.[0-9]+ 
RewriteRule ^(.*)$ - [L] 

 

The code above will allow Baidu's UA/IP to access your site, while blocking all other user agents and IP addresses. Make sure to replace the IP addresses in the code above with Baidu's current IP addresses.

Once you have added the code to your .htaccess file, save the file and check to see if Baidu's UA/IP can access your site. You can use Baidu's Webmaster Tools to verify that your site is being indexed by Baidu.

Thanks & Regrads 
Himanshu Rauthan

Digital Marketing & Inbound Expert In Growth Hacking Technology

View solution in original post

2 Replies 2
SXu
Participant | Platinum Partner
Participant | Platinum Partner

Baidu SEO included domain

SOLVE

Dear Himanshu Rauthan,

 

We tried and it worked, thank you very much for your answer!!!

 

Best regards,

Sharon

himanshurauthan
Solution
Thought Leader | Elite Partner
Thought Leader | Elite Partner

Baidu SEO included domain

SOLVE

Hello @SXu 

If your server is blocking Baidu's User-Agent (UA) or IP address, you will need to modify your server's configuration to allow Baidu's UA/IP to access your site. This can be done by adding the UA/IP to your server's allowlist.

To do this, you will need to access your server's configuration files, which will vary depending on your hosting environment. If you are using a shared hosting environment, you may need to contact your hosting provider for assistance.

Once you have access to your server's configuration files, you can add the following lines of code to your .htaccess file to allowlist Baidu's UA/IP:

# allowlist Baidu UA/IP 
RewriteEngine On 
RewriteCond %{HTTP_USER_AGENT} "Baiduspider" [NC,OR] 
RewriteCond %{REMOTE_ADDR} ^123\.125\.71\. [OR] 
RewriteCond %{REMOTE_ADDR} ^220\.181\.108\. [OR] 
RewriteCond %{REMOTE_ADDR} ^180\.76\.[0-9]+\.[0-9]+ 
RewriteRule ^(.*)$ - [L] 

 

The code above will allow Baidu's UA/IP to access your site, while blocking all other user agents and IP addresses. Make sure to replace the IP addresses in the code above with Baidu's current IP addresses.

Once you have added the code to your .htaccess file, save the file and check to see if Baidu's UA/IP can access your site. You can use Baidu's Webmaster Tools to verify that your site is being indexed by Baidu.

Thanks & Regrads 
Himanshu Rauthan

Digital Marketing & Inbound Expert In Growth Hacking Technology