Markdown Links & Images

Master the creation of links and images in Markdown. Learn all the syntax variations and advanced techniques for rich content.

Jump to Section

Images

Embed images in your Markdown documents.

Basic Images

Markdown
![Markdown Logo](https://markdown-here.com/img/icon256.png)

![Alt text](https://via.placeholder.com/300x200 "Image Title")
Preview

Markdown Logo

Alt text

Use ![alt text](URL) syntax to embed images.

Images with Titles

Markdown
![Beautiful landscape](https://via.placeholder.com/400x200/4CAF50/FFFFFF?text=Landscape "A beautiful mountain landscape")

![Product photo](https://via.placeholder.com/300x300/2196F3/FFFFFF?text=Product "Our best-selling product")
Preview

Beautiful landscape

Product photo

Add titles for image descriptions and tooltips.

Local Images

Markdown
![Logo](./assets/logo.png "Company Logo")

![Screenshot](../images/app-screenshot.jpg)
Preview

Logo

Screenshot

Use relative paths for local images in your project.

Tips & Best Practices

  • Alt text is crucial for accessibility and SEO
  • Use descriptive alt text that explains the image content
  • Optimize image sizes for web performance
  • Consider using CDNs for better image loading

Reference Images

Use reference-style syntax for images, similar to reference links.

Basic Reference Images

Markdown
![Markdown Logo][logo]

![GitHub Logo][github-logo]

[logo]: https://markdown-here.com/img/icon256.png "Markdown Logo"
[github-logo]: https://github.githubassets.com/images/modules/logos_page/GitHub-Mark.png "GitHub Logo"
Preview

Markdown Logo

GitHub Logo

Reference images work like reference links but with exclamation mark.

Multiple Image References

Markdown
Here are some popular logos:

![Google][google-img] ![Facebook][facebook-img] ![Twitter][twitter-img]

[google-img]: https://via.placeholder.com/100x50/4285F4/FFFFFF?text=Google
[facebook-img]: https://via.placeholder.com/100x50/1877F2/FFFFFF?text=Facebook  
[twitter-img]: https://via.placeholder.com/100x50/1DA1F2/FFFFFF?text=Twitter
Preview

Here are some popular logos:

Google Facebook Twitter

Great for documents with many repeated images.

Tips & Best Practices

  • Reference images help organize documents with many images
  • Group image references at the end of sections
  • Use descriptive reference names
  • Easier to update image URLs when centralized

Clickable Images

Make images clickable by combining image and link syntax.

Image Links

Markdown
[![Markdown Logo](https://markdown-here.com/img/icon256.png)](https://markdown-here.com)

[![Click to enlarge](https://via.placeholder.com/200x150)](https://via.placeholder.com/800x600)
Preview

Markdown Logo

Click to enlarge

Wrap image syntax in link syntax to make images clickable.

Complex Image Links

Markdown
[![Product Screenshot](https://via.placeholder.com/300x200/FF5722/FFFFFF?text=Screenshot "Click to see full size")](https://via.placeholder.com/1200x800)

[![Download App](https://via.placeholder.com/200x60/4CAF50/FFFFFF?text=Download "Download from App Store")](https://apps.apple.com/app)
Preview

Product Screenshot

Download App

Combine image titles and link functionality for rich interactions.

Reference Style Clickable Images

Markdown
[![App Screenshot][screenshot]][app-link]

[screenshot]: https://via.placeholder.com/300x200 "App Screenshot"
[app-link]: https://example.com/app
Preview

App Screenshot

Use reference style for complex clickable images.

Tips & Best Practices

  • Perfect for image galleries and product showcases
  • Use clear visual indicators that images are clickable
  • Consider adding captions to explain click behavior
  • Test clickable images across different devices

Advanced Image Techniques

Advanced methods for image control and presentation.

HTML for Image Control

Markdown
<img src="https://via.placeholder.com/400x200" alt="Responsive Image" width="300" height="150">

<img src="https://via.placeholder.com/400x200" alt="Centered Image" style="display: block; margin: 0 auto;">
Preview
<img src="https://via.placeholder.com/400x200" alt="Responsive Image" width="300" height="150"> <img src="https://via.placeholder.com/400x200" alt="Centered Image" style="display: block; margin: 0 auto;">

Use HTML when you need more control over image display.

Image with Caption

Markdown
![Data Visualization](https://via.placeholder.com/500x300/2196F3/FFFFFF?text=Chart)

*Figure 1: Monthly sales data showing growth trend over the last quarter.*
Preview

Data Visualization

Figure 1: Monthly sales data showing growth trend over the last quarter.

Add captions using italic text below images.

Multiple Images

Markdown
![Before](https://via.placeholder.com/200x150/F44336/FFFFFF?text=Before) ![After](https://via.placeholder.com/200x150/4CAF50/FFFFFF?text=After)

**Before and After Comparison**
Preview

Before After

Before and After Comparison

Place images side by side for comparisons.

Tips & Best Practices

  • Use HTML img tags for precise control over dimensions
  • Add captions with italic or bold text for context
  • Consider responsive image techniques for web use
  • Use consistent image sizing throughout your document