Go to the permalinks setting in the wordpress settings page and change the permalink structure to this.
https://mysite.com/%category%/%postname%/
And now add this code in your .htaccess file to achieve that permalink structure.
<IfModule mod_rewrite.c>
RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
Related Posts:
- Rewriting a custom-post-type permalink with taxonomy term?
- Custom Post Type Permalink / Rewrite not working immediately
- Permalink Structure for Multiple Post Type Archives by Taxonomy
- Remove slug in taxonomy url
- Taxonomy, Terms, and Template Files
- custom post type and custom taxonomy permalink
- Is there a way to use regular categories with custom post types?
- Templates for Custom Post Types and Custom Taxonomies
- Dynamic taxonomy in permalink made all other posts NOT FOUND?
- Create permalink structure for one taxonomy archive per custom post type
- Custom Post Type Permalink For Parent/Child, 404 Page Not Found Error
- Custom permalinks
- Understanding Permalinks on Custom Post Types
- Add links to post categories and taxonomies in wysiwyg link modal?
- Rewrite permalinks for custom posttype and custom taxonomy
- How to check if last uri segment is a custom post type or taxonomy term?
- Custom Permalinks for Custom Post Types and Taxonomies
- Custom taxonomy & post slug permalink
- Including two taxonomies in a permalink structure
- WP Rewrite Rules – Custom post type & taxonomy
- Remove base slug in CPT & CT, use CT in permalink
- Maintaining WP_Query Relation Among CPT, Custom Taxonomy, Permalinks- CPT UI
- Custom post type category, taxonomy and URL rewrite problem
- Define permalinks for custom post type by taxonomy in WP 3.4
- Permalink Structure problem with cpt and custom taxonomy
- Custom Taxonomy List links being re-written
- Remove taxonomy slug when not assigning taxonomy with custom post types
- Custom Post Type: How to display all of same taxonomy?
- Custom Post Types, Custom Taxonomies and Permalinks ?
- Custom post type permalinks giving 404s
- Custom Taxonomies: Multiple Hierarchical Permailnks For A Single Post + Prev/Next Links
- Remove “-2” from a Toolset Types URL with the same post name
- Add the .html extension to custom post types
- What is better: Custom Fields vs Custom Taxonomies with Terms for perfomance, scalability and better user experience
- Custom Permalink Tag breaks Pagination
- Custom Permalink with Dynamic Taxonomy for Custom Post Type – Works, but breaks other permalinks
- Custom Permalink for Taxonimie and Custom Post Type
- Programmatically adding posts
- How to create a permalink structure with custom taxonomies and custom post types like base-name/parent-tax/child-tax/custom-post-type-name
- removing custom tax & CPT slug, adding taxonomy term in front of custom type
- multiple url slug for single custom post type
- Custom post type and taxonomy permalinks – Structure
- Custom Post Type and Custom Taxonomy Permalinks
- Custom post types, taxonomies, and permalinks
- Custom Post Type with two hierarchical Custom Taxonomies: strategy to generate best permalink structure
- How to specify URLS for custom posts & taxonomies
- Permalinks not working for custom taxonomy on custom post type
- Permalink Structure CPT With Custom Taxonomy Fails
- Change Permalink Structure for Tag.php template
- Custom Post Type permalink shows wrong page: homepage/index.php
- Custom post type url with category
- Adding custom post category slug in permalink causes 404 error for pages and posts
- How to create custom url structure based on custom post type rewrite slug, taxonomy and category slug?
- Removing custom post type slug from URL
- Customize Custom Post Type URL
- How to have this permalink structure: post_type/postname/custom_inner_page
- Custom taxonomy returns 404
- CPT’s with landing page instead of archive – Url Rewrite?
- Permalink structure with custom taxonomies and custom post type like /parent-tax/child-tax/custom-post-type-name (with no base name)
- permalink /category/post-name with custom post type and taxonomy
- Custom post type and taxonomy permalinks
- Hierarchical permalinks for custom post type and taxonomy
- Custom permalink with child taxonomy terms
- Custom post type Permalinks with hierarchical Taxonomies
- Best way to specify “article type” in URL
- Template files for Custom Post Type and Taxonomy
- Can’t use pagination with custom taxonomy
- How to filter a custom post type by custom taxonomy without 404
- How to get all posts related to particular category name on button click?
- Using page title as a link to term archive
- Is it possible to have hierarchical taxonomy and hierarchical custom post types in one permalink?
- Custom category URL not displaying posts
- Duplicate slug/permalink issue while adding same post name
- Custom Permalink For Custom Post Type – Working Fine But Broken For Pagination
- Set priority to permalinks
- Error 404 change permalink term custom term taxonomy
- Permalinks: custom post type -> custom taxonomy -> custom sub taxonomy -> post
- Pretty Permalinks with CTP and Taxonomies / Hierarchical
- How to change URL structure for custom post type in wordpress? Custom taxonomy + custom Post name [duplicate]
- % encoded URL giving 404 error in WordPress
- Remove CPT Slug with 2 taxonomies and 1 post meta
- Issue with Custom Post Types and Permalinks
- Custom post type URL structure with site.com/custom_taxonomy_slug/post_name
- Pretty permalink structure with multiple (AND OR) taxonomies
- How to have permalink structure based on taxonomy terms
- Multiple post types or single post type with category taxonomy?
- Custom Post type and Taxonomy in post URL error
- How can I add a “fake” parent into the permalink?
- How to retrieve the permalink for a specific (custom) term?
- Remove Custom Taxonomy Slug only without removing Custom post type slug in permalinks
- Permalink Trouble with Custom Post Type
- WordPress Custom Permalink Structure with Custom Post Type and Taxonomies
- Add taxonomy to custom post type archive
- Permalinks Works for Custompost type but not with pages Why?
- Problem with Custom Post Types, Taxonomy, permalink, Archive
- 404 Error On Custom Taxonomy Pages 2, 3, etc
- Different CPT permalink base on taxonomy
- Hide custom post type slug url from search engine [closed]
- Is it possible for post and custom post type to share a category base slug?
- Permalinks for Custom Post Types and Taxonomies