Skip to main content
@capgo/capacitor-downloader Files & Storage Open source

Downloader Capacitor plugin

Download large files in background with progress tracking and pause/resume support

Install

bun add @capgo/capacitor-downloader bunx cap sync
npm, pnpm or yarn
  • npm install @capgo/capacitor-downloader
  • pnpm add @capgo/capacitor-downloader
  • yarn add @capgo/capacitor-downloader

Guide

How to use Downloader in Capacitor

Test on device

Download the Capgo app, then scan the QR code.

Downloader plugin preview QR code

Using @capgo/capacitor-downloader

Capacitor plugin for downloading files with background support. Provides resumable downloads with progress tracking.

Install

bun add @capgo/capacitor-downloader
bunx cap sync

What This Plugin Exposes

  • download - Start a new download task.
  • pause - Pause an active download. Download can be resumed later from the same position.
  • resume - Resume a paused download. Continues from where it was paused.
  • stop - Stop and cancel a download permanently. Downloaded data will be deleted.

Example Usage

download

Start a new download task.

import { CapacitorDownloader } from '@capgo/capacitor-downloader';

const task = await CapacitorDownloader.download({
  id: 'my-download',
  url: 'https://example.com/file.pdf',
  destination: 'downloads/file.pdf'
});

pause

Pause an active download. Download can be resumed later from the same position.

import { CapacitorDownloader } from '@capgo/capacitor-downloader';

await CapacitorDownloader.pause({ id: 'id-123' });

resume

Resume a paused download. Continues from where it was paused.

import { CapacitorDownloader } from '@capgo/capacitor-downloader';

await CapacitorDownloader.resume({ id: 'id-123' });

stop

Stop and cancel a download permanently. Downloaded data will be deleted.

import { CapacitorDownloader } from '@capgo/capacitor-downloader';

await CapacitorDownloader.stop({ id: 'id-123' });

Full Reference

Keep going from Using @capgo/capacitor-downloader

If you are using Using @capgo/capacitor-downloader to plan migration and enterprise operations, connect it with @capgo/capacitor-downloader for the implementation detail in @capgo/capacitor-downloader, Getting Started for the implementation detail in Getting Started, Capgo Enterprise for the product workflow in Capgo Enterprise, Ionic Enterprise Plugin Alternatives for the product workflow in Ionic Enterprise Plugin Alternatives, and Capgo Alternatives for the product workflow in Capgo Alternatives.

FAQ

Downloader plugin FAQ

How do I install the Downloader plugin in a Capacitor app?

Run "bun add @capgo/capacitor-downloader" (or "npm install @capgo/capacitor-downloader"), then run "bunx cap sync" so the iOS and Android projects pick up the native code. Import it from "@capgo/capacitor-downloader" in your app code.

Does @capgo/capacitor-downloader work with React, Vue and Angular?

Yes. Downloader is a Capacitor package, so it works with any web framework that runs inside Capacitor, including Ionic, React, Vue, Angular, Svelte and plain JavaScript.

Which Capacitor version does @capgo/capacitor-downloader support?

Capgo plugins follow Capacitor's major version: use the plugin major version that matches your Capacitor major version (for example plugin v8 with Capacitor 8). The compatibility table in the GitHub README lists the maintained versions.

Is @capgo/capacitor-downloader free and open source?

Yes. The source code is public on GitHub at https://github.com/Cap-go/capacitor-downloader/ and the package is free to install from npm. Bug reports and pull requests are welcome.

Can I update code that uses Downloader without an App Store review?

Installing or upgrading the plugin changes native code, so it needs a new store build. After that, JavaScript, HTML and CSS changes that call the plugin can ship instantly with Capgo live updates.

Ship Downloader changes without waiting for app review

Once the plugin is in your store build, Capgo live updates push your JavaScript, HTML and CSS changes to users in minutes.

Start with Capgo