Home

>

Tools

>

Ghost

>

Releases

>

5.0.0

Ghost Release: 5.0.0

Tag Name: v5.0.0

Release Date: 5/23/2022

Ghost LogoGhost

Open-source publishing platform specifically designed for professional bloggers and publications. Focuses on clean, minimalist writing and publishing experience.

TL;DR

Ghost 5.0.0 introduces major new features including Multiple Newsletters, a new analytics dashboard, and an improved publishing workflow. This is a significant update with breaking changes, including the removal of versioned APIs, legacy product/price helpers, and single author support. The update also includes important bug fixes and comes with Casper v5 theme.

Highlight of the Release

    • Multiple Newsletters support for targeting different audience segments
    • New analytics dashboard with improved insights
    • Enhanced publishing workflow
    • New theme helpers for detecting member features
    • Removal of versioned APIs for simplified development
    • Transition from single author to multiple authors model
    • Updated Casper theme to v5.0.0

Migration Guide

Breaking Changes

Versioned APIs Removed

Ghost has removed versioned APIs in favor of a simpler, unversioned approach. If your code relies on specific API versions:

  • Update all API requests to use the unversioned endpoints
  • Check for any custom headers needed for compatibility
  • Test thoroughly as response formats may have changed

Legacy Product and Price Helpers Removed

The following theme helpers have been removed:

  • @products
  • @product
  • @price
  • @members.products

Replace these with the new tier-based helpers:

  • Use @member.subscriptions instead of @member.products
  • Use the {{price}} helper instead of @price

Single Author Support Removed

Ghost now exclusively uses the multiple authors model:

  • Update any code that relies on author_id or single author concepts
  • Use authors array instead of author or author_id
  • Update any filters that use author_id to use author slugs instead

HTTP/HTTPS Mixed Mode Support Removed

Ghost will no longer automatically upgrade HTTP URLs to HTTPS:

  • Ensure your site is configured with the correct URL protocol
  • Update any hardcoded URLs in your code or content
  • Check theme templates for any protocol-specific code

Members API Site Endpoint Removed

The /members/api/site endpoint has been removed:

  • Update any code that uses this endpoint to use the Content API instead
  • Portal now uses the Content API for site data

Newsletter and Email Changes

  • members_from_address setting is no longer used, use newsletter from address instead
  • email_recipient_filter has been renamed to email_segment
  • newsletter_id has been renamed to newsletter and expects a slug instead of an ID

Migration Steps

  1. Backup your data before upgrading
  2. Check your theme for deprecated helpers and update as needed
  3. Update any custom code or integrations to use the new unversioned APIs
  4. If using custom themes, ensure they're compatible with the multiple authors model
  5. Review your newsletter configuration and update as needed
  6. Test your site thoroughly after upgrading

For Theme Developers

  • Update themes to use the new tier-based helpers
  • Replace any usage of @blog global with appropriate alternatives
  • Update templates to work with multiple authors
  • Test themes with the new Casper v5 as a reference

Upgrade Recommendations

Urgency: Medium to High

This is a major version update (5.0.0) with significant new features and breaking changes. Site owners should plan the upgrade carefully, especially if they use custom themes or have integrations with the Ghost API.

Who should upgrade immediately:

  • Sites that need the multiple newsletter functionality
  • Publishers wanting to take advantage of the new analytics dashboard
  • Developers starting new Ghost projects who want the latest features

Who should wait and plan:

  • Sites with complex custom themes that may use deprecated helpers
  • Sites with custom integrations using versioned APIs
  • High-traffic production sites that should test thoroughly first

Before upgrading:

  1. Create a complete backup of your Ghost installation and database
  2. Review the breaking changes documentation thoroughly
  3. Test the upgrade in a staging environment if possible
  4. Check custom themes for compatibility issues
  5. Update any custom code that interacts with the Ghost API

For sites with custom themes or integrations, allocate time to test and fix any issues that arise after upgrading. The removal of versioned APIs and legacy helpers may require significant updates to custom code.

Bug Fixes

Fixed Importing Posts with Newsletter Assignment

Fixed an issue where importing posts with a newsletter assigned would fail due to missing newsletter relationships. The importer now properly handles posts linked to newsletters.

Fixed Newsletter Header Image Storage

Resolved a bug where newsletter header images were being saved as absolute URLs instead of in the transform-ready format. This ensures proper handling of header images across different environments.

Fixed Member Exports for Large Sites

Improved the performance of member exports to prevent timeouts when exporting large numbers of members. A custom query was implemented to optimize the export process.

Fixed Newsletter Editing Limit Checks

Fixed an error in newsletter editing limit checks that was causing undefined values to be used in comparisons, resulting in incorrect limit enforcement.

Fixed Bulk Unsubscribe Counts

Resolved an issue where bulk unsubscribing members would return the number of deleted newsletter relations instead of the number of members with cleared newsletters.

New Features

Multiple Newsletters

Ghost now supports creating and managing multiple newsletters, allowing publishers to segment their audience and deliver more targeted content. This feature enables:

  • Creating newsletters with different designs, settings, and branding
  • Targeting specific audience segments with relevant content
  • Allowing members to subscribe to specific newsletters based on their interests
  • Managing newsletter subscriptions independently

New Analytics Dashboard

The new analytics dashboard provides improved insights into site performance, member growth, and newsletter engagement:

  • Better visualization of key metrics
  • More detailed member analytics
  • Enhanced newsletter performance tracking
  • Improved data filtering and segmentation options

Enhanced Publishing Workflow

The publishing workflow has been significantly improved:

  • More intuitive interface for drafting, reviewing, and publishing content
  • Better scheduling options
  • Improved collaboration features
  • Enhanced newsletter integration in the publishing process

New Theme Helpers for Member Features

New theme helpers have been added to make it easier to detect and work with member features:

  • Simplified detection of member status and capabilities
  • Better integration with the membership system
  • More flexible theme customization based on member data

Security Updates

Improved Authentication and Authorization

  • Fixed an issue where suspended users could update their last_seen timestamp through certain API endpoints
  • Enhanced validation for user status values to prevent potential security issues
  • Added proper permission checks for newsletter and label access

API Security Enhancements

  • Added 'Content-Version' header to outgoing webhook requests to improve API version compatibility
  • Improved validation rules for API requests
  • Removed unknown properties from API responses to prevent information leakage

Configuration Security

  • Renamed session_secret setting to be more specific and secure
  • Improved handling of sensitive configuration values

Performance Improvements

Optimized Member Exports

A significant performance improvement has been made to the member export functionality, particularly for large sites. The implementation now uses a custom query that prevents timeouts when exporting large amounts of member data.

Improved Database Operations

Several database operations have been optimized:

  • Disabled model auto-refresh when processing email batches to reduce unnecessary database queries
  • Added transaction support for newsletter editing to improve data consistency and performance
  • Improved handling of large tables with the addition of algorithm=copy for MySQL operations

Enhanced API Response Handling

The API response handling has been streamlined:

  • Removed unnecessary data from API responses
  • Simplified settings API to only return key and value
  • Improved error handling and validation

Impact Summary

Ghost 5.0.0 represents a significant evolution of the platform with a focus on improving the publishing and newsletter experience. The introduction of multiple newsletters transforms Ghost from a single-newsletter platform to a sophisticated email marketing system capable of targeting different audience segments. This is complemented by a new analytics dashboard that provides deeper insights into content and membership performance.

The update also includes substantial architectural changes, most notably the removal of versioned APIs, which simplifies the development experience but requires updates to existing integrations. The shift away from the single author model to exclusively using multiple authors reflects Ghost's evolution as a collaborative publishing platform.

For developers and theme creators, this update requires attention to several breaking changes, particularly around deprecated helpers and API endpoints. Site owners will need to ensure their themes are compatible with the new version, especially if they use custom themes.

The performance improvements, particularly around member exports and database operations, will benefit larger Ghost installations with substantial member bases. Security enhancements further strengthen the platform's robustness.

Overall, Ghost 5.0.0 delivers significant value for publishers looking to grow their audience through more sophisticated newsletter strategies while continuing to evolve the platform's architecture for better performance and developer experience.

Full Release Notes

➡️ For an overview of the changes see the 5.0 Changelog.
⚠️ Before updating please read the breaking changes guide.


  • ✨ Added support for Multiple Newsletters - Rishabh Garg
  • ✨ Added new analytics dashboard - Fabien 'egg' O'Carroll
  • ✨ Added new publishing workflow - Kevin Ansfield
  • ✨ Added theme helpers for detecting member features - Hannah Wolfe
  • 🐛 Fixed importing posts with a newsletter assigned - Matt Hanley
  • 🐛 Fixed newsletters' header_image saved as absolute url - Simon Backx
  • 🔥 Removed versioned APIs - Hannah Wolfe
  • 🔥 Removed legacy product + price helpers from themes - Hannah Wolfe
  • 🔥 Removed members/api/site - Rishabh Garg
  • 🔥 Removed support for http/https mixed mode - Hannah Wolfe
  • 🔥 Removed legacy single author support - Naz
  • 🎨 Comes with Casper v5 - Sodbileg Gansukh

View the changelogs for full details:

🪄 Love open source? We're hiring Node.js Engineers to work on Ghost full-time

Statistics:

File Changed300
Line Additions1,165
Line Deletions13,631
Line Changes14,796
Total Commits250

User Affected:

  • Can now create and manage multiple newsletters for different audience segments
  • Access to a new analytics dashboard with improved insights
  • Need to be aware of breaking changes when upgrading from previous versions
  • May need to update themes that use deprecated helpers

Contributors:

ErisDSSimonBackxrenovate-botnazallouisrshbhgrgrenovate[bot]matthanleydaniellockyeraileenkevinansfieldpeterzimon