Skip to content
pubscout

blurhash

1.2.0, released 2 years ago by raincal.com

A very compact representation of a placeholder for an image.

WASM-ready
$ flutter pub add blurhash
Source repository

What it does

Provides encoding and decoding capabilities for BlurHash strings. Allows generating a compact placeholder hash from raw image bytes and decoding a hash back into image bytes.

AI-written summary of version 1.2.0, based on the package's README and metadata. Report an inaccuracy

Use it when

  • You need compact string placeholders for images while they load
  • You want to encode images to BlurHash on supported platforms

Skip it when

  • You do not need image placeholders
  • You need high-level cached image widgets instead of low-level decoding

Strengths

  • Supports Android, iOS, and Web
  • Compact representation for placeholders

Weaknesses

  • Limited documentation beyond basic README examples
  • Platform-specific exceptions can be thrown during decoding

Setup

Kind
Plugin (native code)
Effort
Low
Code generation
No
Direct dependencies
4

Add blurhash as a dependency in pubspec.yaml.

void blurHashDecode() async {
  Uint8List? imageDataBytes;
  try {
    imageDataBytes = await BlurHash.decode(blurhash, 20, 12);
  } on PlatformException catch (e) {
    throw Exception(e.message);
  }
}

Alternatives

Packages that do the same job and could replace blurhash.

Works with

Packages commonly used together with blurhash: ones it builds on, ones built on it, and its own family.