Skip Navigation
Show nav
Dev Center
  • Get Started
  • Documentation
  • Changelog
  • Search
  • Get Started
    • Node.js
    • Ruby on Rails
    • Ruby
    • Python
    • Java
    • PHP
    • Go
    • Scala
    • Clojure
    • .NET
  • Documentation
  • Changelog
  • More
    Additional Resources
    • Home
    • Elements
    • Products
    • Pricing
    • Careers
    • Help
    • Status
    • Events
    • Podcasts
    • Compliance Center
    Heroku Blog

    Heroku Blog

    Find out what's new with Heroku on our blog.

    Visit Blog
  • Log inorSign up
Hide categories

Categories

  • Heroku Architecture
    • Compute (Dynos)
      • Dyno Management
      • Dyno Concepts
      • Dyno Behavior
      • Dyno Reference
      • Dyno Troubleshooting
    • Stacks (operating system images)
    • Networking & DNS
    • Platform Policies
    • Platform Principles
  • Developer Tools
    • Command Line
    • Heroku VS Code Extension
  • Deployment
    • Deploying with Git
    • Deploying with Docker
    • Deployment Integrations
  • Continuous Delivery & Integration (Heroku Flow)
    • Continuous Integration
  • Language Support
    • Node.js
      • Working with Node.js
      • Troubleshooting Node.js Apps
      • Node.js Behavior in Heroku
    • Ruby
      • Rails Support
      • Working with Bundler
      • Working with Ruby
      • Ruby Behavior in Heroku
      • Troubleshooting Ruby Apps
    • Python
      • Working with Python
      • Background Jobs in Python
      • Python Behavior in Heroku
      • Working with Django
    • Java
      • Java Behavior in Heroku
      • Working with Java
      • Working with Maven
      • Working with Spring Boot
      • Troubleshooting Java Apps
    • PHP
      • PHP Behavior in Heroku
      • Working with PHP
    • Go
      • Go Dependency Management
    • Scala
    • Clojure
    • .NET
      • Working with .NET
  • Databases & Data Management
    • Heroku Postgres
      • Postgres Basics
      • Postgres Getting Started
      • Postgres Performance
      • Postgres Data Transfer & Preservation
      • Postgres Availability
      • Postgres Special Topics
      • Migrating to Heroku Postgres
    • Heroku Key-Value Store
    • Apache Kafka on Heroku
    • Other Data Stores
  • AI
    • Model Context Protocol
    • Vector Database
    • Working with AI
    • Heroku Inference
      • Quick Start Guides
      • Inference API
      • Inference Essentials
      • AI Models
  • Monitoring & Metrics
    • Logging
  • App Performance
  • Add-ons
    • All Add-ons
  • Collaboration
  • Security
    • App Security
    • Identities & Authentication
      • Single Sign-on (SSO)
    • Private Spaces
      • Infrastructure Networking
    • Compliance
  • Heroku Enterprise
    • Enterprise Accounts
    • Enterprise Teams
    • Heroku Connect (Salesforce sync)
      • Heroku Connect Administration
      • Heroku Connect Reference
      • Heroku Connect Troubleshooting
  • Patterns & Best Practices
  • Extending Heroku
    • Platform API
    • App Webhooks
    • Heroku Labs
    • Building Add-ons
      • Add-on Development Tasks
      • Add-on APIs
      • Add-on Guidelines & Requirements
    • Building CLI Plugins
    • Developing Buildpacks
    • Dev Center
  • Accounts & Billing
  • Troubleshooting & Support
  • Integrating with Salesforce
  • Add-ons
  • All Add-ons
  • Memetria for Redis®*
Memetria for Redis®*

This add-on is operated by Stovepipe Studios, Inc.

Valkey 7.2, Instrumented and Scaled

Memetria for Redis®*

Last updated February 14, 2025

Table of Contents

  • Provisioning the Add-on
  • Memetria Dashboard
  • Local Setup
  • Language-Specific Integrations
  • Plan Management
  • Removing the Add-on
  • Additional Support

Memetria for Redis is an add-on for a high-performance, durable Redis database. It provides:

  • Autoscaling: resize without downtime, and automatically upgrade at plan limits
  • Encryption: dual and TLS-only connectivity
  • Continuous backups with easy import and export
  • Detailed monitoring to track large keys and monitor memory allocations

Provisioning the Add-on

Add Memetria for Redis to an app via the Heroku CLI:

$ heroku addons:create memetria-redis:minidev
Adding memetria-redis:minidev to fancy-slinky-2001... done, v24 ($14/mo)
Your Memetria database has been built. You can find MEMETRIA_REDIS_URL in your Heroku config
Created memetria-redis-adjacent-38367 as MEMETRIA_REDIS_URL
Use `heroku addons:docs memetria-redis:minidev` to view documentation

After provisioning Memetria for Redis, the MEMETRIA_REDIS_URL config var is available in the attached app’s configuration. It contains the Redis URI for your Redis server. You can see the config var via the heroku config:get command:

$ heroku config:get MEMETRIA_REDIS_URL
redis://default:PASSWORD@HOST:PORT

For example:

$ heroku config:get MEMETRIA_REDIS_URL
redis://default:gnysfn55t65g72ntd4g0a6h8ea91ca9v@smart-panda.memetria.net:10042

Provisioning Multiple Memetria for Redis Add-ons

You can attach multiple Memetria for Redis add-ons to your app multiple times to create separate dedicated databases for different purposes:

$ heroku addons:add memetria-redis:minidev
Adding memetria-redis:minidev to fancy-slinky-2001... done, v25 ($14/mo)
Your Memetria database has been built. You can find MEMETRIA_REDIS_URL in your Heroku config
Created memetria-redis-curved-92092 as MEMETRIA_REDIS_AQUA_URL
Use `heroku addons:docs memetria-redis:minidev` to view documentation

Each Memetria for Redis database has its own URL in your Heroku app config:

$ heroku config | grep MEMETRIA
MEMETRIA_REDIS_URL: redis://default:PASSWORD@HOST:PORT
MEMETRIA_REDIS_AQUA_URL: redis://default:PASSWORD@HOST:PORT

Attaching Memetria for Redis to Other Apps

After provisioning Memetria for Redis, you can attach it to other Heroku apps. Find the addon ID with heroku addons

$ heroku addons

Add-on                                          Plan     Price      State
──────────────────────────────────────────────  ───────  ──────────  ───────
memetria-redis (memetria-redis-adjacent-38367)  minidev  $14/mo      created
 └─ as MEMETRIA_REDIS
memetria-redis (memetria-redis-curved-92092)    minidev  $14/mo      created
 └─ as MEMETRIA_REDIS_AQUA

And attach the database to an app using the addon ID:

$ heroku addons:attach memetria-redis-adjacent-38367

Memetria Dashboard

The Memetria dashboard provides graphs, alerts, diagnostic information, and more. Access the Memetria dashboard through your app’s Heroku Dashboard page or through the Heroku CLI:

$ heroku addons:open memetria

You can also consult Memetria’s own documentation at www.memetria.com/docs.

Managing Redis Versions

Memetria for Redis supports multiple versions. You can choose the Redis version that is appropriate for your application or use Memetria’s recommended setting in the Settings panel of the Memetria dashboard.

Security patches and minor versions are automatically applied.

Custom Configuration

Many settings can be configured directly from your Memetria dashboard. If you need custom configuration, you can click the Support button in the Memetria dashboard or email us at support@memetria.com and we’ll work with you to implement the best configuration for your particular needs.

Rotating Credentials

To rotate credentials for your Memetria for Redis server, click the Support button in the Memetria dashboard and request a credential rotation. This rotation pushes a new MEMETRIA_REDIS_URL to your application and restarts your dynos with the new credentials. Memetria’s support team confirms the rotation before disabling the old credentials.

Local Setup

Environment Setup

After provisioning Memetria for Redis, you can replicate its config vars locally for development environments that require it.

Use the local Heroku CLI command to configure, run, and manage process types specified in your app’s Procfile. Heroku Local reads configuration variables from a .env file. Use heroku config to view an app’s configuration variables in a terminal. Use the following command to add a configuration variable to a local .env file:

$ heroku config:get MEMETRIA_REDIS_URL -s  >> .env

Your Memetria Redis URL is sensitive and should not be committed to source control. In Git exclude the .env file with: echo .env >> .gitignore.

For more information, see the Heroku Local article.

Language-Specific Integrations

Using Redis with Ruby

Add the redis and connection_pool gems to your Gemfile:

    gem 'connection_pool'
    gem 'redis'

Run bundle install to install them.

For Rails apps, configure your cache store to use Memetria for Redis, in config/environments/production.rb:

    config.cache_store = :redis_cache_store, {
      url: ENV["MEMETRIA_REDIS_URL"],
    }

If you’re using Sidekiq, supply the Memetria for Redis URL in a Sidekiq initializer (config/initializers/sidekiq.rb):

    Sidekiq.configure_server do |config|
      config.redis = { url: ENV["MEMETRIA_REDIS_URL"] }
    end

Create a Client

You can create a client with:

    redis = Redis.new(url: ENV["MEMETRIA_REDIS_URL"])

Or access through a connection pool for use within multithreaded environments like Sidekiq and Puma:

    redis = ConnectionPool.new { Redis.new(url: ENV["MEMETRIA_REDIS_URL"]) }
    redis.with do |client|
      client.set("greeting", "hello, world!")
      client.get("greeting") # => 'hello, world!'
    end

Using Redis with Python

Install the redis package:

    pip install redis

To use Redis as a cache backend for your Django app with django-redis:

    CACHES = {
        "default": {
            "BACKEND": "django_redis.cache.RedisCache",
            "LOCATION": os.getenv("MEMETRIA_REDIS_URL"),
            "OPTIONS": {
                "CLIENT_CLASS": "django_redis.client.DefaultClient",
            }
        }
    }

To use Memetria for Redis as your session store, you must also update your Django session engine settings:

    SESSION_ENGINE = "django.contrib.sessions.backends.cache"
    SESSION_CACHE_ALIAS = "default"

Create a Client

Create your Redis connection with:

    import os, redis

    redis = redis.from_url(os.getenv("MEMETRIA_REDIS_URL"))

Using Redis with Node.js

Install the ioredis package using npm:

$ npm install ioredis

You can then create your Redis connection with:

    const Redis = require("ioredis");
    const redis = new Redis(process.env.MEMETRIA_REDIS_URL);

Using Redis with PHP

The predis library is recommended. Add the library to your composer.json file:

    composer require predis/predis

And connect by using the MEMETRIA_REDIS_URL config var:

    $redis = new Predis\Client(getenv('MEMETRIA_REDIS_URL'));

Plan Management

Automatic Upgrades

Automatic Upgrades are enabled by default on all Memetria for Redis databases. If you reach the memory limits of your plan, Memetria automatically upgrades you to the next size and send you a notification.

If your memory usage returns within the plan limits, no action is necessary: Memetria restores your plan to the previous size without affecting your application.

If you choose to make the automatic upgrade permanent, you must change the plan size on Heroku. See Migrating Plans for more info.

If you choose not to keep the upgraded plan size, Memetria begins enforcing the limits of your Heroku plan after notifying you.

You can disable automatic upgrades at any time from the Settings menu in the Memetria dashboard.

Migrating Plans

When you alter the plan of your Memetria for Redis database, your hostname stays the same and your database stays online and available.

You can choose new plan sizes via your Heroku dashboard, or with the CLI:

$ heroku addons:upgrade memetria-redis:dev
Changing memetria-redis-shaped-48055 on calm-beach-06843 from memetria-redis:minidev to memetria-redis:dev... done, ($39/mo)
Migration to the Development plan started. Your Redis URL will remain the same.

Removing the Add-on

You can remove Memetria for Redis from your app via the Heroku CLI:

This action destroys all associated data and you can’t undo it! Download the most recent backup from the dashboard before removing the add-on.

You can download your latest backup from your Memetria for Redis database by visiting your Memetria dashboard (heroku addons:open memetria-redis) and navigating to the Backup list by clicking Settings then Backups.

After downloading your data, remove your Memetria for Redis addon:

$ heroku addons:destroy memetria-redis
  !    WARNING: Destructive Action
  !    This command will affect the app: example-app
  !    To proceed, type "example-app" or re-run this command with --confirm example-app
  > example-app
 Removing memetria-redis:minidev from example-app... done, v25 ($14/mo)

Additional Support

Use the Support button in the Memetria dashboard or email support@memetria.com to get help with any aspect of your Memetria for Redis server, including custom configurations.

Keep reading

  • All Add-ons

Feedback

Log in to submit feedback.

Zara 4 Memetria Monitoring for Redis®*

Information & Support

  • Getting Started
  • Documentation
  • Changelog
  • Compliance Center
  • Training & Education
  • Blog
  • Support Channels
  • Status

Language Reference

  • Node.js
  • Ruby
  • Java
  • PHP
  • Python
  • Go
  • Scala
  • Clojure
  • .NET

Other Resources

  • Careers
  • Elements
  • Products
  • Pricing
  • RSS
    • Dev Center Articles
    • Dev Center Changelog
    • Heroku Blog
    • Heroku News Blog
    • Heroku Engineering Blog
  • Twitter
    • Dev Center Articles
    • Dev Center Changelog
    • Heroku
    • Heroku Status
  • Github
  • LinkedIn
  • © 2025 Salesforce, Inc. All rights reserved. Various trademarks held by their respective owners. Salesforce Tower, 415 Mission Street, 3rd Floor, San Francisco, CA 94105, United States
  • heroku.com
  • Legal
  • Terms of Service
  • Privacy Information
  • Responsible Disclosure
  • Trust
  • Contact
  • Cookie Preferences
  • Your Privacy Choices