
# React Photo Album
[](https://www.npmjs.com/package/react-photo-album)
[](https://github.com/igordanchenko/react-photo-album/blob/main/.size-limit.json)
[](https://github.com/igordanchenko/react-photo-album/blob/main/LICENSE)
React Photo Album is a responsive photo gallery component with rows, columns,
and masonry layouts. Inspired by
[react-photo-gallery](https://github.com/neptunian/react-photo-gallery),
re-engineered from the ground up.
## Overview
- **Built for React:** works with React 18+
- **SSR friendly:** produces server-side rendered markup that looks
pixel-perfect on the client even before hydration
- **Responsive images:** responsive images with automatic resolution switching
are supported out of the box
- **Feature-packed:** supports 3 layout options (rows, columns, and masonry),
responsive images, custom data attributes, and is fully configurable and
customizable
- **TypeScript:** type definitions come built-in with the package
- **Performance:** built with performance in mind to support large photo albums
## Layouts
### Rows

### Columns

### Masonry

## Documentation
[https://react-photo-album.com/documentation](https://react-photo-album.com/documentation)
## Examples
[https://react-photo-album.com/examples](https://react-photo-album.com/examples)
## Changelog
[https://github.com/igordanchenko/react-photo-album/releases](https://github.com/igordanchenko/react-photo-album/releases)
## Installation
```shell
npm install react-photo-album
```
## Requirements
- React 18+
- Node 18+
- modern ESM-compatible bundler
## Minimal Setup Example
```tsx
import { RowsPhotoAlbum } from "react-photo-album";
import "react-photo-album/rows.css";
const photos = [
{ src: "/image1.jpg", width: 800, height: 600 },
{ src: "/image2.jpg", width: 1600, height: 900 },
];
export default function Gallery() {
return