I'm updating a site from Craft 2 to Craft 3 and can't find the equivalent of the 'Category Sources' plugin? It's really useful when it comes to restricting the source for related entries by the category the entry belongs to. Does anybody know of an alternative solution?


  • An alternative solution would be to create the plugin in your own but why don't you use the Craft 3 version of the plugin? If it has any bugs you can submit them, I'm sure they'll fix it – Robin Schambach Jul 22 '18 at 15:52
  • I don't see a Craft 3 version of the plugin anywhere? It would be great if there was! – shandy Jul 22 '18 at 16:32
  • 1
    Click on "Branch" select v2 and you'll see the Craft 3 version – Robin Schambach Jul 22 '18 at 16:34

There's a Craft 3 port of Category Sources in the v2 branch for the repo. It doesn't appear to be published to Packagist and the Plugin Store, which means you'll need to add the URL for the plugin's Git repository to your project's composer.json file in order for Composer to find it.

Add the following to the root of your composer.json file:

"repositories": {
    "craftcms/category-sources": {
        "type": "git",
        "url": "git@github.com:pixelandtonic/CategorySources.git",
        "trunk-path": "v2"

You might also need to add the following to composer.json:

"minimum-stability": "dev",
"prefer-stable": true,

Then, you can do composer require craftcms/category-sources to actually download the plugin.

Note: I haven't tested this plugin myself, and the fact that it isn't released probably means it's not completely ready for primetime (it might not even work at all, with recent versions of Craft 3). Proceed with caution; you might also want to get in touch with Pixel & Tonic to hear if the plugin is likely to get a proper release anytime soon.

| improve this answer | |
  • 2
    Thanks for the help so far. I think I'll check with Pixel & Tonic to be on the safe side! – shandy Jul 22 '18 at 17:00
  • Has it been abandoned? :/ – benface Jan 30 '19 at 16:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.