Skip to content
PictureToLink
Menu
Image Sharing

Direct Link, Viewer Link or Embed Code: Which to Use?

Direct links, viewer pages, HTML, BBCode and Markdown explained, with a table showing which image link works on forums, email, Discord, eBay and GitHub.

By PictureToLink Team · · 7 min read
Facts checked against official sources on

On this page

Use a viewer link (a share page) when you are sending a picture to a person, and a direct link (the URL of the image file itself) when an app, chat or website needs to display the image. An image embed code is a direct link wrapped in the syntax a particular place understands: HTML for websites and email templates, BBCode for forums, and Markdown for GitHub and documentation. Pick the format by where the image is going, not by the image.

Most image hosts, PictureToLink included, give you several versions of the same link. On PictureToLink you choose them from the link menu after uploading on the homepage. Here is what each one looks like for an image with the ID abc123:

FormatExampleWhat it is
Direct linkhttps://picturetolink.com/i/abc123.jpgThe image file itself, nothing else
Share page (viewer link)https://picturetolink.com/v/abc123A simple web page that shows the image
HTML embed<a href="…/v/abc123"><img src="…/i/abc123.jpg" alt="" width="1920" height="1280"></a>Code for web pages and HTML emails
BBCode[img]https://picturetolink.com/i/abc123.jpg[/img]Code for forums
Markdown![](https://picturetolink.com/i/abc123.jpg)Code for GitHub, READMEs and docs

There is a sixth option, BBCode linked, which wraps the forum code in a link to the share page so readers can click through. The three embed codes all contain the direct link. They only differ in the wrapper around it.

A direct link points straight at the image file. Open one in a browser and you see the picture on a blank background, with no page around it. Use it when software needs to fetch and display the image: chat apps such as Discord, form fields that ask for an "image URL", and embed codes.

The URL usually ends in a file extension such as .jpg, .png, .gif or .webp.

Use a direct link when software needs to fetch and display the image:

  • Chat apps that turn image URLs into inline pictures, such as Discord. Discord's File Attachments FAQ describes a chat setting under which "when an image is posted as a link, the image will be displayed instead of the text link."
  • Form fields that ask for an "image URL", such as a profile picture field, a product feed or a spreadsheet image function.
  • Inside any of the embed codes below.

Do not send a direct link to someone who just wants to look at a photo. It works, but on a phone it opens as a bare file, and some browsers offer to download it instead of showing it.

A viewer link, which PictureToLink calls a share page, opens a normal web page with the image displayed properly at any screen size. It is the friendliest link to paste into a text message, an email or a social media message.

Two details about PictureToLink's share pages:

  • They carry no ads, so the person you send it to just sees your image.
  • They ask search engines not to index them, and the link is random rather than guessable. That does not make the image private: anyone who has the link can view it, and they can pass it on.

A viewer link is the wrong choice inside an embed code or an "image URL" box. Those expect an image file, and a web page will show up as a broken image. This is the single most common reason a picture fails to appear on a forum or website.

HTML, BBCode and Markdown embeds

HTML embed

HTML is the language of web pages, so HTML embed code works on websites, blogs that accept custom HTML, and HTML email templates. PictureToLink's HTML embed shows the image and makes it a link to the share page:

<a href="https://picturetolink.com/v/abc123"><img src="https://picturetolink.com/i/abc123.jpg" alt="" width="1920" height="1280"></a>

Two things are worth editing before you paste it:

  1. Fill in the alt text. Write a short description of the image between the quotes. Screen readers read it aloud, and it appears if the image fails to load.
  2. Keep the width and height. They tell the browser the image's proportions before it loads, which stops the page jumping around. To show the image smaller, change the display size with your site's CSS or editor rather than deleting these.

If you only want the image without the click-through link, keep just the <img ...> part and delete the <a ...> and </a> around it.

BBCode

Forums such as phpBB, XenForo and MyBB use BBCode rather than HTML. The tag is [img] around a direct link. Our full guide to BBCode image tags covers linked images, sizing and the differences between forum packages.

Markdown

Markdown is the lightweight syntax used on GitHub, in README files and in many documentation and note-taking tools. GitHub's formatting guide describes the pattern: an exclamation mark, alt text in square brackets, then the image link in parentheses. PictureToLink's Markdown code leaves the alt text empty, so add your own description between the brackets:

![Screenshot of the settings page](https://picturetolink.com/i/abc123.jpg)

For images that live in your own repository, GitHub recommends relative links instead of full URLs. Our Markdown image syntax guide goes deeper.

Choose the format by where the image is going. Send a share page to people in texts, chats and ordinary emails. Use a direct link for Discord and any form or app asking for an "image URL". Use BBCode on forums, Markdown on GitHub, and the HTML embed for websites, HTML email templates and eBay descriptions.

Where the image is goingBest formatNotes
A text message, chat with a friend, or social media DMShare pageOpens as a normal page on any phone
A regular email you are typingShare pagePaste it into the message. Recipients click to view.
An HTML email template or newsletter toolHTML embed (image only)Classic Outlook blocks automatic picture downloads by default, and Gmail users can turn on "Ask before displaying external images", so some readers see a placeholder until they allow images
DiscordDirect linkShown inline if the reader has link previews on and the channel allows embedded links
Forums (phpBB, XenForo, MyBB, vBulletin)BBCode or BBCode linkedUse the forum's own attachment feature if it has one
GitHub issues, pull requests and README filesMarkdownAdd alt text between the square brackets
A website or blog postHTML embedAdd alt text. Keep width and height.
eBay item descriptionHTML, image onlySee the note below
A form or app asking for an "image URL"Direct linkA share page will appear broken

A note on eBay. eBay's links policy says listings cannot contain links that send buyers to other sites, with limited exceptions, and that allowed links must use HTTPS. eBay's developer guide to description HTML lists links to externally hosted images among those exceptions, and recommends that images in descriptions should not exceed 700 pixels in width. So in an eBay description, use only the <img> part of the HTML embed with the direct link, and remove the <a> link to the share page. Your main listing photos are a separate thing, uploaded through eBay's own listing form.

If you are not sure how to get a link in the first place, start with our guide on how to get an image URL from a phone or computer.

A working direct link can still fail to display when the host blocks hotlinking, the platform only shows images uploaded through its own uploader, the community has turned embeds off, the reader's email app blocks remote images, the link is not HTTPS, or the image has been deleted.

In more detail:

  • The host blocks hotlinking. Showing an image from another site's server uses that site's bandwidth. Many sites check where a request comes from and refuse to serve images to other websites. Image hosts like PictureToLink exist precisely so that embedding is allowed. Our explainer on hotlinking covers the etiquette.
  • The platform does not allow outside images. Some platforms only display pictures uploaded through their own uploader, or strip links from posts. eBay's link rules above are one example.
  • The community has turned embeds off. On Discord, a channel's "Embed Links" permission controls whether links show embedded content, according to Discord's channel permissions guide. Forum administrators can switch off image tags too.
  • The reader's email app blocks remote images. As noted in the table, many email apps hold back images until the reader allows them.
  • The link is not secure. Platforms such as eBay require HTTPS, and browsers may block http:// images on secure pages.
  • The image has gone. If the host deleted it, every link stops working at once. On PictureToLink that happens when you delete an image with its private delete link, when an auto-delete time you chose passes, or after 12 months without any views.

Next step

Decide where the image is going, then upload it and pick the matching format from the link menu: share page for people, direct link for apps, and HTML, BBCode or Markdown for websites, forums and GitHub. Use Copy all if you uploaded several images and need every link in the same format.