WordPress post-name permalink redirects to site.com

Try separating the second location block: location /blog { alias /var/www/wordpress-site/; try_files $uri $uri/ /blog/index.php?$args; } location ~ \.php$ { fastcgi_split_path_info ^(/blog)(/.*)$; include snippets/fastcgi-php.conf; include fastcgi_params; fastcgi_pass unix:/var/run/php/php7.2-fpm.sock; fastcgi_param SCRIPT_FILENAME $request_filename; } Hope this helps!

Trouble with CPT Child 404

You can’t have both a page and a Custom Post type with the same slug, in your case videos. See: https://core.trac.wordpress.org/ticket/38599 for a ticket recommending this be changed in core. A few solutions: Change either the page or the post type to video instead of video Follow the Template Hierarchy and create a archive-videos.php with … Read more

WP admin page gives 404

Perhaps the siteurl or home value got modified when you tried to modify the site URL in WP admin? If so, it might make the front-end and the WP admin inaccessible because it is looking for WordPress in a directory in which it doesn’t exist. Fixing it in the database If you have access to … Read more

404 on paginated blog pages

I managed to work around this issue. I recently updated my site to WordPress 5.7 and was getting 404 Errors on every page except the home page. After a lot of debugging I found out that wp-includes/class-wp.php was setting the is_404 variable because of a missing comment <!–nextpage–> in the $post->post_content. (Line 694) I tried … Read more