Drupal is a registered trademark of Dries Buytaert
drupal 11.3.7 Update released for Drupal core (11.3.7)! drupal 11.2.11 Update released for Drupal core (11.2.11)! drupal 10.6.7 Update released for Drupal core (10.6.7)! drupal 10.5.9 Update released for Drupal core (10.5.9)! cms 2.1.1 Update released for Drupal core (2.1.1)! drupal 11.3.6 Update released for Drupal core (11.3.6)! drupal 10.6.6 Update released for Drupal core (10.6.6)! cms 2.1.0 Update released for Drupal core (2.1.0)! bootstrap 8.x-3.40 Minor update available for theme bootstrap (8.x-3.40). menu_link_attributes 8.x-1.7 Minor update available for module menu_link_attributes (8.x-1.7). eca 3.1.1 Minor update available for module eca (3.1.1). layout_paragraphs 2.1.3 Minor update available for module layout_paragraphs (2.1.3). ai 1.3.3 Minor update available for module ai (1.3.3). ai 1.2.14 Minor update available for module ai (1.2.14). node_revision_delete 2.0.3 Minor update available for module node_revision_delete (2.0.3). moderated_content_bulk_publish 2.0.52 Minor update available for module moderated_content_bulk_publish (2.0.52). klaro 3.0.10 Minor update available for module klaro (3.0.10). klaro 3.0.9 Minor update available for module klaro (3.0.9). layout_paragraphs 2.1.2 Minor update available for module layout_paragraphs (2.1.2). geofield_map 11.1.8 Minor update available for module geofield_map (11.1.8).

masonry

9,027 sites Security covered
View on drupal.org

Provides an API for integrating the jQuery Masonry plugin with Drupal.

From desandro.github.io/masonry:

Masonry is a JavaScript grid layout library. It works by placing elements in optimal position based on available vertical space, sort of like a mason fitting stones in a wall.

As this is an API module, you will likely want to download some of the sub-modules below that implement this API to provide Masonry functionality to various parts of your site.
Additionally, no styling is provided by this API module or any of the sub-modules. You will need to add your own CSS as described here.

Sub-Modules

Drupal 8/9 indications:

Install and manage dependencies - option 1

Check documentation on how to handle external dependencies here: https://www.drupal.org/docs/develop/using-composer/manage-dependencies#t...

Install and manage dependencies via composer - option 2

1. Install the module itself :
composer require drupal/masonry

2. Install wikimedia/composer-merge-plugin :
composer require wikimedia/composer-merge-plugin

3. Edit your "merge-plugin" section under "extra" in your *root* composer.json so it looks like:

  "extra": {
   "merge-plugin": {
      "include": [
         "modules/contrib/masonry/composer.libraries.json"
      ]
   }
}

Beware to change the path to your contrib module folder if under web or docroot for instance

4. Run a locked update, or a module update:
composer update --lock
composer update drupal/masonry

Install and manage dependencies manually - option 3

1. Download and unzip masonry module from https://www.drupal.org/project/masonry
and place it into /modules/contrib folder.

2. Download and unzip masonry from http://masonry.desandro.com/
and place it into /libraries folder so the following path exists
/libraries/masonry/dist/masonry.pkgd.min.js

3. Download and unzip imagesloaded from http://imagesloaded.desandro.com/
and place it into /libraries folder so the following path exists:
/libraries/imagesloaded/imagesloaded.pkgd.min.js

Drupal 7 indications:

jQuery Compatibility

The Masonry plugin requires jQuery v1.6 or greater.
As Drupal 7 only ships with jQuery v1.4.4, you'll need to upgrade jQuery to a later version. You can do this by installing one of the following modules:

Required Modules

Installation

  1. Download and enable the required modules listed above
  2. Update jQuery (see 'jQuery Compatibility' above)
  3. Download the Masonry plugin :
    • v2 with branch 2.x. Rename the file to be located at : /sites/.../libraries/masonry/jquery.masonry.min.js
    • v3 with branch 3.x. Rename the file to be located at :
      /sites/.../libraries/masonry/masonry.pkgd.min.js
  4. Branch 3.x only: you need to create a directory for imagesloaded in the libraries directory and then download the imagesloaded library from http://imagesloaded.desandro.com/imagesloaded.pkgd.min.js. Rename it to be located at :
    /sites/.../libraries/imagesloaded/imagesloaded.pkgd.min.js
  5. Download and enable Masonry API (and optionally any sub-modules, see above)
  6. Check /admin/reports/status to ensure the Masonry plugin was properly detected

Activity

Total releases
1
First release
Aug 2025
Latest release
8 months ago
Release cadence
Stability
100% stable

Releases

Version Type Release date
4.1.0 Stable Aug 5, 2025