We are already in WordPress! After a long time of inactivity in the blog I have decided to resume it by changing CMS for better administration and usability for readers 😉 previously and for about 8 years I used Blogger, a platform that I have a lot of affection for, but I must say that this little bird finished fledging and it was time to «leave the nest to take flight », Metaphorically speaking clearly.
Precisely during the Blogger to WordPress migrationOne of the problems that many bloggers can give headaches, cause them to lose Google traffic and fill the Webmaster tools panel with 404 errors, is mobile redirection, remember that in Blogger the URL when you visit from a cell phone ends in ? m = 1, for example: http://miblogbonito.com/2015/11/nombre-super-entrada.html?m = 1
When changing the platform, that ending in the URL is still maintained, so a 301 redirect must be made, that is, take the visitor from that old mobile URL to the new one; sin? m = 1.
And to achieve this, there are 2 ways, one of them through the plugin Blogger 301 Redirect, but since I do not like to install plugins when you can enter code directly, we will then see how to do it manually and in a simple way for any user.
Modifying the .htaccess file
Step 1:.- Log in to the cPanel of your hosting and open the File Manager, choosing the option 'Root directory for' and activating the box 'Show hidden files' (dotfiles).
Step 2:.- In the new tab that will open from the public_html folder, look for the file .htaccess and with a right click on it and the option 'Code edit' or from the same panel with «Code editor» we proceed with the next step, which is the most important. (If you want to make a backup of that file first).
Step 3:.- When opening with the code editor you will see that the .htaccess file contains the following:
# BEGIN WordPress
RewriteEngine On
RewriteBase /
RewriteRule ^ index \ .php $ - [L]
RewriteCond% {REQUEST_FILENAME}!-F
RewriteCond% {REQUEST_FILENAME}!-D
RewriteRule. /index.php [L]
# END WordPress
After RewriteBase / paste the following:
RewriteEngine On
RewriteCond% {QUERY_STRING} ^ m = 1 $
RewriteRule ^ (. *) $ / $ 1? [R = 301, L]
Finally leaving the .htaccess file as follows:
# BEGIN WordPress
RewriteEngine On
RewriteBase /
RewriteEngine On
RewriteCond% {QUERY_STRING} ^ m = 1 $
RewriteRule ^ (. *) $ / $ 1? [R = 301, L]
RewriteRule ^ index \ .php $ - [L]
RewriteCond% {REQUEST_FILENAME}!-F
RewriteCond% {REQUEST_FILENAME}!-D
RewriteRule. /index.php [L]
# END WordPress
What is in red is the change we have made, which is the 301 redirect of the mobile version? M = 1 of blogger, to the new URL after the migration to WordPress.
Finally save the changes in the .htaccess file and immediately do the test by visiting from google any result of your site that is indexed and the 404 error problem with the mobile version will have been solved 🙂
Another easier way: with Yoast SEO
If you have installed this fantastic plugin to improve the SEO of your blog, you should know that in the "Tools" section, there is a "File Editor", which precisely gives you quick access to edit the .htaccess file in a a jiffy, without entering your cPanel or with FTP clients.
There you just add the codes as mentioned above, save the changes to the .htaccess and problem fixed instantly.
I hope this solution has helped you (if you had this problem), or if you have a blog on Blogger and you plan to migrate to WordPress with your own hosting one day. If not, I would be happy if you share the post anyway, because someone might be interested 😀
interesting trick, thanks.
To you Manuel, thanks to one of your comments I was encouraged to return to WordPress 😀
ahhh, well we hope wordpress is very useful for you then 🙂
Great contribution, by the way, how do you redirect blogger to wordpress?
thanks and regards.
Thanks spend! For the redirection I use the plugin «Blogger To WordPress Redirection», who is in charge of doing the magic 😉
It helped me! Thank you!
How good Florence! Thanks to you for the comment 🙂
Hello Marcelo, I have a website for almost half a year with a blogger and I am doing well and well I wanted to ask you if that redirection that blogger does when you enter from a cell phone «? M = 1» affects my positioning in blogger or how can I change o that does not appear, greetings.
Thanks in Advance 🙂
Hi Enrique, the parameter "? M = 1" as far as I know cannot be avoided for the mobile redirect in Blogger. However, in my experience, it does not affect the indexing in the SERPS or the SEO of your blog 😀
Greetings.
Fantastic! I just did a migration from blogger to wordpress and the urls positioned with M1 gave an error. Now it works great!
Thank you!