From what you’ve described, it sounds like the theme doesn’t have an attachment.php template to handling displaying the actual attachment page.
You check on the attachment page, by going to Appearance->Editor, and checking for an attachment.php; however, I believe that answer is incorrect. WordPress should default to displaying the image on the normal blog index page, if I’m not mistaken. Which means the error could have something to do with a custom permalink structure.
Have you changed the permalink structure? If so, try changing it back to default and see if you still get a 404.
Related Posts:
- Images attached to posts from library link to 404 error page
- Programmatically adding images to media library
- how to get original image using wp_get_attachment_image_src
- Can I attach image to post without adding it to post?
- Uploaded images don’t show in Media Library if there are special characters in IPTC Keywords
- wp_get_attachment_image_src and server path
- How to find attachment by it’s name?
- How do I delete all generated images from my server except those currently used in posts
- Theme Customiser Image Control
- How can I hide media library images from general users?
- Get attachment ID of author_meta image – Attachment Metadata
- Associate an existing image with a post
- Programatically creating image attachments from local URLs and setting featured image
- How do i upload an image and return the image id?
- Get Attachment ID from URL [duplicate]
- How to remove title attribute from gallery links and images
- copy attachment title to description and alt text
- Get an image from url in front end submission form
- Open the attachment details modal
- How to upload image without post ID using the new media uploader?
- How do I delete thousands of unattached images?
- Applying class to links around self hosted images embedded to posts/pages
- Regex to turn embedded images in to attachments
- Re-process Images
- Show prev and next post links for parent post of current image in attachment page?
- Pulling Post Image Attachments in WordPress 3.9
- Link Featured Thumb to Attachment Page, If Possible
- Regenerate missing _wp_attachment_metadata
- Make alt text required when setting a featured image
- Attachment page 404 not found when image is attached to post
- Image still linked as attachment to page even though it has been deleted
- Best way to strip character entities (%20 etc)
- Is there a way to get attachment data?
- How to change image url?
- Add a new data attribute in tag
- Link to full size image or attachment page in photo theme
- get the image of the post
- add the post as canonical for attachment page wordpress
- media_sideload_image with rewritten urls?
- Add an attribute to attachments
- Some images not found 404 in localhost
- Out of memory error reporting
- How can I attach hotlinked images in posts/pages within the same server?
- Multiple images in one attachment page
- WordPress Image Attachment using remote image
- Exclude images from “inserted into post” when trying to get attachments
- WordPress adds extra width to post images container boxes
- Handling image uploads without thickbox
- Pull images from the gallery
- Customizing the attachement page to show rest of all images in a gallery from post
- Help to upload post attachments from Ajax
- Rewrite all article pictures to link to file
- wp get attachment image always gives me thumbnail
- Call to undefined function wp_generate_attachment_metadata()
- Images give 404 after changing default domain
- How do you import images from a URL in your post?
- Get images attached to a specific page
- Retrieve Image Attachments Getting Post Thumbnail Image First
- One picture belonging different galleries?
- Migrated site – Images have 404 error
- WordPress Attachments with old images
- How to get image URL from media_sideload_image?
- How to test if there are no more previous or next image on attachment page?
- Show last 12 uploaded images on home page, but only from posts
- Random Characters in the end of every image url in post
- Failed to load resource:404 image
- Excluding post thumbnail from the attachment.php when using wordpress gallery
- Output posts attached images as thumbnails linked to full-size with lightbox class
- Can i have 2 separate Galleries on 2 separate pages each go to a DIFFERENT Attachment.php file?
- How to change an image source when rendering on frontend?
- Custom image size not displaying with wp_get_attachment_image()
- Images not loading on webpage, and links to other media give 404 Not Found
- SQL: How to find all attachments that are not used in any posts/pages/custom_post_types
- attachment_fields_to_save first parameter is null
- How to disable post-thumbnail from generation?
- WordPress 404 Images – Images not found after deleted from media
- How to Make Only Images Connected to a Post Show? Not Entire Media Collection?
- Get “Image CSS Class” value from the Advanced Options section
- Uploaded images not showing properly using wordpress
- Resized images not working – 404
- After I upload a file to library its name converted to dashes
- attachment.php & flexslider—linking thumbnail to specific image
- Create a custom attachment thumbnail for quick page load
- Surround uploaded image link with div
- Extract url from next_image_link
- Setting name of attachment URL
- Lots of attachments is causing slow load
- Show title when inserting single images
- Upload unnattached image from frontend
- Image attachement management – a philosophical question
- wp_get_attachment_link() add rel attribute if the link points to direct image
- greater flexibility in targeting images attached to page
- Stop Attachment image names from taking top level permalink
- How to access & display images from a post without textual content ( and vice versa) according to best wordpress practices
- Some images 404
- My subdirectory sites images (except webP) are throwing to 404 page even they are exist
- Image Attachments Query Not Working If Post Is Loaded Via Ajax
- How can I use an image from an external source without uploading it to the media library
- Remove one srcset entry from wp_get_attachment_image
- Attachment tag archive