A Chrome Extension that replaces your new tab page with beautiful, high-resolution photos from Unsplash and Pexels.
- Dynamic background photos on every new tab
- Choose between Unsplash and Pexels as your photo source
- Favorite photos and browse your collection
- Favorites sync across devices through Chrome sync
- Carousel mode to rotate through your favorites
- Pin any photo as a fixed background for every new tab
- Preloaded image queue for instant transitions
- Clock with smart greeting messages
- Debug panel for inspecting queue state
Install Tabr from the Chrome Web Store
git clone https://github.com/Moolan-d/tabr.git
cd tabr
npm install
npm run buildThen load the .output directory as an unpacked extension in Chrome (chrome://extensions/ > Developer mode > Load unpacked).
Tabr uses the Unsplash API by default, and can switch to Pexels. Unsplash includes a built-in trial key (limited to 10 requests). For either source, you can configure your own key:
- Go to Unsplash Developers and register as a developer.
- Visit Your Apps and click on one of your applications to open its details page.
- On the application page (
https://unsplash.com/oauth/applications/<app-id>), copy the Access Key shown on the page.
- Open a new tab in Chrome, click the Settings button (top-right corner), select Unsplash under Source, paste the key into the Unsplash Access Key field, and click Save.
The new key takes effect immediately — no reload required.
- Create a free API key at Pexels API.
- Open Settings → Source, select Pexels, paste the key, and click Save.
Pexels is optional; the built-in trial key only applies to Unsplash.
# Build once
npm run build
# Watch mode - rebuilds on file changes
npm run devsrc/
├── providers/ # Photo source abstraction
│ ├── types.ts # Photo, PhotoSource, FavoritePhoto interfaces
│ ├── unsplash.ts # Unsplash PhotoSource implementation
│ ├── pexels.ts # Pexels PhotoSource implementation
│ └── registry.ts # Source registration and management
│
├── services/ # Core business logic (no React dependency)
│ ├── cache.ts # Chrome storage cache with TTL
│ ├── favorites.ts # Favorites CRUD + random pick for carousel
│ ├── favorites-sync.ts # chrome.storage.sync mirror with tombstones
│ ├── preload-queue.ts # Preloaded image queue (capacity 2, 10min TTL, 3 retries)
│ └── photo-service.ts # Central orchestrator, subscribe/notify state
│
├── hooks/
│ └── usePhotoService.ts # React bridge via useSyncExternalStore
│
├── components/ # Presentational components
│ ├── Background.tsx
│ ├── BottomBar.tsx
│ ├── Clock.tsx
│ ├── DebugPanel.tsx
│ └── SettingsMenu.tsx
│
└── entrypoints/
└── newtab/
└── main.tsx # Thin shell (~80 lines)
Design principle: React components only subscribe and render. All business logic, caching, and timers live in the service layer.
Implement the PhotoSource interface and register it:
import type { PhotoSource, Photo } from './providers/types';
import { sourceRegistry } from './providers/registry';
const mySource: PhotoSource = {
id: 'my-source',
label: 'My Source',
async fetchRandom(): Promise<Photo> {
// fetch from your API
return {
url: '...',
photographerName: '...',
photographerLink: '...',
originalLink: '...',
source: 'my-source',
};
},
};
sourceRegistry.register(mySource);No changes needed in the service or UI layers.
- CI: Every pull request runs typecheck and build checks
- Release: Pushes to
maintriggersemantic-release, which analyzes commit messages and creates a new version automatically (feat:= minor,fix:= patch) - Package: New releases are built and zipped via
wxt zip, then attached to the GitHub Release automatically - Publish: Submitting to the Chrome Web Store is manual. Run the Release workflow from the Actions tab (
workflow_dispatch) with an existing tag, e.g.v1.6.0. It builds that tag and runswxt submit.
Publishing is deliberately manual: the Chrome Web Store rejects a version that already exists, so it must not fire automatically after a manual upload.
- WXT - Browser extension framework
- React 18 + TypeScript
- Tailwind CSS
- Unsplash and Pexels APIs

