Before starting the steps, I recommend taking the database backup so that if anything goes wrong then you have everything in your hands. It always worked fine for me but you never know if something goes wrong.
So I hope you have done with the database backup so lets start with the process of how to add /blog/ in Front of Your WordPress Posts URLs.
Follow these simple steps:
Step 1 – (Open Permalink Page)
To open the permalink page, please go to “Settings” from the left menu and then choose “permalinks” from the sub menu pallet. It would be 6th option in the sub menu pallet. Please check the screenshot for reference.
Step 2 – (Choose Custom structure)
Now as you are on the settings page, Please choose the “Custom Structure” option. You can find this option under “Common Settings”.
Note: The default structure there would be “http://yourdomain.com/%postname%” without quotes.
All Done 🙂
Note: Make sure your .htaccess file at root has write permission so that rewrite rules will get updated otherwise screen will ask you to add the updated code to your .htaccess file.
Issues you may face once you add /blog/ in Front of Your WordPress Posts URLs
After making changes to the permalink structure, you may notice that if you have created a custom post type then /blog/ will also be added to the slug of posts under that custom post type.
How to resolve this?
Just choose false for “With Front” of that post type to resolve the issue of /blog/ added to the slog of your custom post type posts too. Check the reference screenshot below: