Book a call Free rebuild
Home/Glossary/Astro/Astro Image Component

Astro Image Component

By Seahawk November 16, 2026

Astro glossaryAstro's Image component, from astro:assets, resizes images, converts them to modern formats, and sets their dimensions so pages do not shift while loading.

The <Image /> component, imported from astro:assets, optimizes an image for the web: it resizes it, converts it to a modern format such as WebP, and sets its width and height so the page does not jump while it loads (good for CLS). <Picture /> does the same with several formats or sizes at once.

Images stored in src/ are imported and processed; images in public/ are served as they are. Remote images are processed only from domains you allow in the config. On prerendered pages the work happens at build time; on on-demand pages, when the page is requested. The alt text is required.

Source: Astro docs: Images.

Em Workers

EmDash and Astro sites at revolutionary pricing.

Lightning-fast, secure websites delivered on EmDash and Astro. For the AI-curious bunch.