# Code Node external module not working

**URL:** <https://community.n8n.io/t/code-node-external-module-not-working/88425>\
**Category:** Questions\
**Tags:** core, node\
**Created:** [March 14, 2025, 7:25pm UTC](https://community.n8n.io/t/code-node-external-module-not-working/88425 "2025-03-14T19:25:03Z")\
**Posts on this page:** 1\
**Showing post:** 4

<div class="post-metadata">

**Author:** ![ThinkBot](https://dub1.discourse-cdn.com/n8n/user_avatar/community.n8n.io/thinkbot/32/62172_2.png) [@ThinkBot](https://community.n8n.io/u/ThinkBot)\
**Post date:** [March 14, 2025, 7:56pm UTC](https://community.n8n.io/t/code-node-external-module-not-working/88425/4 "2025-03-14T19:56:11Z")

</div>

This may help further:

> [@The definitive guide to custom NPM modules for self-hosted instances](http://community.n8n.io/t/the-definitive-guide-to-custom-npm-modules-for-self-hosted-instances/50948/2):
>
> Hey @adomakins, Welcome to the community tada I am a big fan of this but can you maybe clean it up a little bit to keep it friendly slight_smile I would also like to add an other option is to use a Dockerfile with FROM n8nio/n8n:latest USER root RUN npm install -g ytdl-core USER node You can then update your Compose file replace image with build like below. n8n: container\_name: n8n build: . restart: always ports: - 5678:5678 environment: - NODE\_FUNCTIO…

---

_[View the full topic](https://community.n8n.io/t/code-node-external-module-not-working/88425)._
