404 Page not found error

Dokan Multi Vendor Documentation

What if you face any 404 error on your online store while using Dokan? Here is the probable fixes for you if you face any 404 error for your online store.

So basically, 404 error occurs due to the things below:-

  1. Missing pages
  2. Wrong/no shortcode
  3. Pages are not selected in the settings
  4. Wrong permalink structure
  5. Duplicate Pages

How to check 404 Error

Missing Pages: Dokan installs 3 different pages in your WordPress system when you activate the plugin for the first time

  1. Dashboard– This is the most important page and you must have this page installed with the shortcode [dokan-dashboard]
  2. Store List– This is an optional page. If you want to show a list of all the stores in your site, then you can create a page with the shortcode [dokan-stores]
  3. My Orders– This too is an optional page. If you want the customers to view all their orders in a separate page, then you can create a page with the shortcode [dokan-my-orders]

Wrong or No Shortcode: The page items are fetched with some specific shortcodes. If you mistype the shortcode or accidentally remove the shortcode from the page, then that might cause a 404 error.

Select Pages on Settings:Dokan page settings‘ is located on WP-admin → Dokan → Settings → Page Settings. No matter what the page name is or its URL, you must select the page from here. And do not forget to place the correct shortcodes on those pages.

Dokan has a static templating system which requires the permalink to be in a required format. You have to set the permalinks to Post name and Product for Dokan to work perfectly. It is also a search engine friendly URL structure and human readable as well.

Select Post Name under Common Settings.

This is a screenshot of Dokan common settings

Select Custom Base/product/ under Product Permalinks.

This image shows Product permalink to solve 404 error

How to set the permalinks for Dokan

  1. Login to WordPress admin.
  2. Navigate to Settings → Permalinks
  3. Select “Post Name” for common posts
  4. Select “Custom Base” for product permalinks and write /product on the box.
  5. Hit Save Changes and you are done.

In case of new add-ons

If you have installed a new add-on for Dokan and getting a 404 error on the page for that add-on. Or can not find the newly installed plugins menu, just navigate to Settings → Permalinks and hit the “Save Changes” button. It will be solved.

This will flush the permalink structure and rewrite rule.