PHPackages                             craftpulse/craft-tweet-feed - 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. craftpulse/craft-tweet-feed

ActiveCraft-plugin

craftpulse/craft-tweet-feed
===========================

Get the latest tweets from a Twitter handle with your own design

4.2.0(3y ago)221[3 PRs](https://github.com/craftpulse/craft-tweet-feed/pulls)MITPHPPHP ^8.0.2

Since Dec 17Pushed 2y ago1 watchersCompare

[ Source](https://github.com/craftpulse/craft-tweet-feed)[ Packagist](https://packagist.org/packages/craftpulse/craft-tweet-feed)[ RSS](/packages/craftpulse-craft-tweet-feed/feed)WikiDiscussions v4 Synced 1mo ago

READMEChangelog (7)Dependencies (3)Versions (19)Used By (0)

Tweet Feed plugin for Craft CMS 4.x
===================================

[](#tweet-feed-plugin-for-craft-cms-4x)

Get the latest tweets from a Twitter handle with your own design

[![Screenshot](resources/img/plugin-logo.png)](resources/img/plugin-logo.png)

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

[](#requirements)

This plugin requires Craft CMS 3.5.0 or later. We utilise Guzzle 6 and up (7 included) and Twitter v2.0.

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

[](#installation)

To install the plugin, follow these instructions.

1. Open your terminal and go to your Craft project:

    ```
     cd /path/to/project

    ```
2. Tell Composer to load the plugin:

    ```
     composer require percipiolondon/craft-tweet-feed

    ```
3. In the Control Panel, go to Settings → Plugins and click the “Install” button for Tweet.

Tweet Feed Overview
-------------------

[](#tweet-feed-overview)

This plugin provides a Twitter feed from a specific Twitter handle.

Configuring Tweet Feed
----------------------

[](#configuring-tweet-feed)

To make this happen, you need to make an app in the [Developers Portal](https://developer.twitter.com/en/portal/dashboard). Make sure it's not a standalone app because we use the Twitter API 2.0.

Create your keys and tokens and paste them into the plugin settings page. Make sure you create an OAuth 1.0a and generate the access tokens.

Besides the keys and tokens, we also require the Twitter user id to provide the tweets from a specific handle. If you don't know the id, you can look it op on [this site](https://codeofaninja.com/tools/find-twitter-id/).

You can provide all of this inside of your environment file.

[![Screenshot](resources/img/settings.png)](resources/img/settings.png)

Using Tweet Feed
----------------

[](#using-tweet-feed)

To make use of Tweet Feed, we created a Craft variable to fetch.

The `craft.tweetfeed.tweets()` function can have 3 parameters.

#### First param: amount of results (default: 100)

[](#first-param-amount-of-results-default-100)

The first one will ask for the number of results you want to receive. There's a maximum of 100 results that can be fetched. Here's a list of all the [Twitter API v2 rate limits](https://developer.twitter.com/en/docs/twitter-api/rate-limits).

*example: 3*

#### Second param: types of fields (default: null)

[](#second-param-types-of-fields-default-null)

The types of fields are the data you want to receive from Twitter. By default, the id and text are provided. We also add the `entities` so you can already use the tweet url. To know all the options, you can visit the [Tweet object](https://developer.twitter.com/en/docs/twitter-api/data-dictionary/object-model/tweet) page.

Always provide the list with a comma as separation.

*example: author\_id,context\_annotations*

#### Third param: extra parameters (default: '')

[](#third-param-extra-parameters-default-)

If you want to extend the query, you can add extra parameters to the url. The `max_results` and `tweet.fields` are already used in the previously shown parameters. To know which kind of parameters excists, you can visit the [GET /2/users/:id/tweets](https://developer.twitter.com/en/docs/twitter-api/tweets/timelines/api-reference/get-users-id-tweets) page and scroll to 'Query parameters'.

To provide these parameters for our plugin, use the following example. You can tie parameters to each other by using `&`.

*example: &amp;exclude=retweets,replies&amp;user.fields=id*

### Twig example

[](#twig-example)

```
{% set tweets = craft.tweetfeed.tweets(3,'author_id,context_annotations','&exclude=retweets,replies&user.fields=id') %}

{% for tweet in tweets %}

       {{ tweet.text }}

{% endfor %}

```

#### urlify twig extension filter

[](#urlify-twig-extension-filter)

If you want to parse the URLs and hashtags into clickable urls, you can use the `| urlify` filter. You need to pass down the full object to get the filtered tweet text back.

```
{% set tweets = craft.tweetfeed.tweets(3,'author_id,context_annotations','&exclude=retweets,replies&user.fields=id') %}

{% for tweet in tweets %}

       {{- tweet | urlify | raw -}}

{% endfor %}

```

#### Use cache tag to reduce calls

[](#use-cache-tag-to-reduce-calls)

There is a limit on API calls per day. If you have a high traffic site, we recommend using the `cache` tag from CraftCMS to reduce calls.

For example:

```
{% cache for 1 day %}
   {% set tweets = craft.tweetfeed.tweets(3,'author_id,context_annotations','&exclude=retweets,replies&user.fields=id') %}

   {% for tweet in tweets %}

          {{ tweet.text }}

   {% endfor %}
{% endcache %}

```

Tweet Feed Roadmap
------------------

[](#tweet-feed-roadmap)

Some updates to do and ideas for potential features:

- GQL support

Brought to you by [percipiolondon](https://percipio.london)

###  Health Score

27

—

LowBetter than 49% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity63

Established project with proven stability

 Bus Factor1

Top contributor holds 64.3% 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

Every ~64 days

Recently: every ~123 days

Total

12

Last Release

901d ago

Major Versions

1.0.2 → 4.0.0-beta.12022-04-20

1.1.0 → 4.1.0.12022-07-22

1.1.0.1 → 4.2.02023-02-06

### Community

Maintainers

![](https://www.gravatar.com/avatar/5cc936921e382ceab892ad03aa12acc365be0992e066c72b37004995847ca31e?d=identicon)[craftpulse](/maintainers/craftpulse)

---

Top Contributors

[![michtio](https://avatars.githubusercontent.com/u/5818021?v=4)](https://github.com/michtio "michtio (9 commits)")[![cookie10codes](https://avatars.githubusercontent.com/u/20947573?v=4)](https://github.com/cookie10codes "cookie10codes (4 commits)")[![EmilyRackliffe](https://avatars.githubusercontent.com/u/47784491?v=4)](https://github.com/EmilyRackliffe "EmilyRackliffe (1 commits)")

---

Tags

cmstwitterCraftcraftcmscraft-plugintweets

### Embed Badge

![Health badge](/badges/craftpulse-craft-tweet-feed/health.svg)

```
[![Health](https://phpackages.com/badges/craftpulse-craft-tweet-feed/health.svg)](https://phpackages.com/packages/craftpulse-craft-tweet-feed)
```

###  Alternatives

[nystudio107/craft-seomatic

SEOmatic facilitates modern SEO best practices &amp; implementation for Craft CMS 5. It is a turnkey SEO system that is comprehensive, powerful, and flexible.

1741.4M46](/packages/nystudio107-craft-seomatic)[wrav/oembed

A simple plugin to extract media information from websites, like youtube videos, twitter statuses or blog articles.

36205.0k3](/packages/wrav-oembed)[verbb/image-resizer

Resize assets when they are uploaded.

127269.1k7](/packages/verbb-image-resizer)[verbb/tablemaker

Create customizable and user-defined table fields.

40168.8k1](/packages/verbb-tablemaker)[verbb/hyper

A user-friendly links field for Craft.

24130.9k9](/packages/verbb-hyper)[verbb/social-poster

Automatically post entries to social media.

918.5k](/packages/verbb-social-poster)

PHPackages © 2026

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