PHPackages                             ralfhortt/term-thumbnails - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. ralfhortt/term-thumbnails

ActiveWordpress-plugin

ralfhortt/term-thumbnails
=========================

Post Thumbnails for WordPress Terms

2.1.0(6y ago)194↓100%1[1 issues](https://github.com/Horttcore/Term-Thumbnails/issues)GPL-3.0-or-laterPHPCI passing

Since Sep 8Pushed 1mo ago1 watchersCompare

[ Source](https://github.com/Horttcore/Term-Thumbnails)[ Packagist](https://packagist.org/packages/ralfhortt/term-thumbnails)[ RSS](/packages/ralfhortt-term-thumbnails/feed)WikiDiscussions master Synced 2mo ago

READMEChangelog (1)DependenciesVersions (2)Used By (0)

Term Thumbnails
===============

[](#term-thumbnails)

[![CI](https://github.com/Horttcore/Term-Thumbnails/actions/workflows/ci.yml/badge.svg)](https://github.com/Horttcore/Term-Thumbnails/actions/workflows/ci.yml)

Post Thumbnails for WordPress Terms.

Requirements
------------

[](#requirements)

- PHP 8.4+
- WordPress 6.0+

Installation
------------

[](#installation)

- Drop the plugin into your plugin directory and activate it in the WordPress backend.
- Go to any term page and add an image.

Gutenberg Block
---------------

[](#gutenberg-block)

The plugin registers a `term-thumbnails/term-thumbnail` block for use in block-theme templates and the Query Loop block. It supports:

- **Image size** — choose any registered image size
- **Aspect ratio** — Original, 1:1, 4:3, 3:4, 3:2, 2:3, 16:9, 9:16
- **Scale** — Cover, Contain, Fill (shown when an aspect ratio is set)
- **Focal point** — drag-to-set crop focus (shown when scale is Cover or Fill)

Template Tags
-------------

[](#template-tags)

```
get_term_thumbnail_id( int $term_id ): int|false
has_term_thumbnail( int $term_id ): bool
the_term_thumbnail( string|array $size = 'post-thumbnail', string|array $attr = '' ): void
get_term_thumbnail( int $term_id, string|array $size = 'post-thumbnail', string|array $attr = '' ): string
```

Hooks
-----

[](#hooks)

### Filters

[](#filters)

FilterDescription`term-thumbnail-taxonomies`Array of taxonomy slugs that support thumbnails. Defaults to all registered taxonomies.`{$taxonomy}-has-thumbnails`Return `false` to disable thumbnail support for a specific taxonomy.`term_thumbnail_size`Override the image size used by `get_term_thumbnail()`.`term_thumbnail_html`Filter the final `` HTML returned by `get_term_thumbnail()`.### Examples

[](#examples)

```
// Disable thumbnails for categories.
add_filter( 'category-has-thumbnails', '__return_false' );

// Limit thumbnails to a custom taxonomy only.
add_filter( 'term-thumbnail-taxonomies', fn() => [ 'genre' ] );
```

Screenshots
-----------

[](#screenshots)

### Term listing

[](#term-listing)

[![Term listing](https://camo.githubusercontent.com/b40ba963c3f2c66774be7e9ae31674346d4b253d5610e3749d085b3555f2042b/68747470733a2f2f7261772e6769746875622e636f6d2f486f727474636f72652f5465726d2d5468756d626e61696c732f6d61737465722f73637265656e73686f742d312e706e67)](https://raw.github.com/Horttcore/Term-Thumbnails/master/screenshot-1.png)

### Term listing with image

[](#term-listing-with-image)

[![Term listing with image](https://camo.githubusercontent.com/815738b778616db24bad897602764291e10149ff044e3fc0942ca7b206cbe1e1/68747470733a2f2f7261772e6769746875622e636f6d2f486f727474636f72652f5465726d2d5468756d626e61696c732f6d61737465722f73637265656e73686f742d322e706e67)](https://raw.github.com/Horttcore/Term-Thumbnails/master/screenshot-2.png)

### Term edit page

[](#term-edit-page)

[![Term edit page](https://camo.githubusercontent.com/d0c239c9737970b1850e8eda8d48ecde1e2b60646846246ba3856857c9bba8b9/68747470733a2f2f7261772e6769746875622e636f6d2f486f727474636f72652f5465726d2d5468756d626e61696c732f6d61737465722f73637265656e73686f742d332e706e67)](https://raw.github.com/Horttcore/Term-Thumbnails/master/screenshot-3.png)

### Term edit page with image

[](#term-edit-page-with-image)

[![Term edit page with image](https://camo.githubusercontent.com/3b5171dd8540f22a0337d80b2bb76a0b9439312da02948d773a691921ebcb907/68747470733a2f2f7261772e6769746875622e636f6d2f486f727474636f72652f5465726d2d5468756d626e61696c732f6d61737465722f73637265656e73686f742d342e706e67)](https://raw.github.com/Horttcore/Term-Thumbnails/master/screenshot-4.png)

Changelog
---------

[](#changelog)

### v3.0.0

[](#v300)

- Complete rewrite: PSR-4 namespaced PHP 8.4 architecture
- Replaced jQuery admin JS with vanilla JS + `@wordpress/api-fetch`
- Replaced `wp_ajax_*` handlers with the WordPress REST API (`register_term_meta` with `show_in_rest: true`)
- Added Gutenberg block (`term-thumbnails/term-thumbnail`) with aspect ratio, scale, image size, and focal point controls
- Build tooling migrated to `@wordpress/scripts`
- Added Pest test suite

### v2.1.0

[](#v210)

- Added: Composer support

### v2.0.1

[](#v201)

- Fix: Remove warning

### v2.0.0

[](#v200)

- Switch from options to term meta structure

### v1.0.2

[](#v102)

- Fix: Missing term images for custom taxonomies

### v1.0.1

[](#v101)

- Added: Screenshots
- Added: readme.txt
- Enhancement: Security improvements
- Fix: Typo on term edit page

### v1.0

[](#v10)

- Initial release

###  Health Score

33

—

LowBetter than 74% of packages

Maintenance42

Moderate activity, may be stable

Popularity14

Limited adoption so far

Community8

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Unknown

Total

1

Last Release

2435d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/45d54752dcf3da868ffe4a5ad2b876d6acb911fd914700b52e4d4777ff7d4a02?d=identicon)[Ralf Hortt](/maintainers/Ralf%20Hortt)

---

Top Contributors

[![Horttcore](https://avatars.githubusercontent.com/u/503252?v=4)](https://github.com/Horttcore "Horttcore (17 commits)")

---

Tags

post-thumbnailstaxonomyterm-thumbnailswordpresswordpress-terms

### Embed Badge

![Health badge](/badges/ralfhortt-term-thumbnails/health.svg)

```
[![Health](https://phpackages.com/badges/ralfhortt-term-thumbnails/health.svg)](https://phpackages.com/packages/ralfhortt-term-thumbnails)
```

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
