Last modifiedby & filed under Kontakt Scripting (KSP) - Basics, UIs, Tutorials, Scripts and Tools, Kontakt Scripting (KSP) :: Basics.

Using the Script Tabs in Kontakt is not the only option we got. We can also “outsource” our scripts and store them into our resource container. We can then load them into one of our script tabs. This article and the video shows how this is done.

Please accept YouTube cookies to play this video. By accepting you will be accessing content from YouTube, a service provided by an external third party.

YouTube privacy policy

If you accept this notice, your choice will be saved and the page will refresh.



Sometime it is very useful to outsource our scripts into the resource container. The most common application is a script tab locker to further protect the script tabs from being accessed by any users.

create a new instrument


1. create a new instrument


2. save it into a new folder

create a new resource container


3. open the instrument options

4. and create a new resource container


5. navigate to the folder where you have just stored your instrument nki into.

6. enter a name for your resource container. Usually “resources” or “z-resources” would be some clear naming (use the prefix “z” to put it on the bottom in any standard file browser)

7. hit “save”


8. confirm. Kontakt will automatically create the resource container, an nkr file. It also creates an nkc file and all necessary folders.
Into these folder we can then put in our resources like pictures, impulse responses and script files.


9. now a summary appears which lists all files that have been packed into the resource container from the Resources folders. Since we just created a new container nothing will be there to be packed into the resources.nkr file. But next time when we update this container our script file will be packed into it (see below)

create a txt file for the script


11. open a new file browser now (the windows explorer or finder on a mac) and navigate to your instrument folder. You can now see a “Data” folder, a “Resources” folder and the actual resource containers: the nkr and the nkc files.

12. open the Resources folder now


13. and go to the scripts folder


14. inside the scripts folder create a new text file and name it e.g. “engine” or use any name you want to call your script. (Of course you can also use your favorite text editor and save the txt file into the scripts folder from there)

start coding your script


15. Open the txt file with your favorite code or text editor. In this case we use the standard windows notepad

16. Write your script and save it as with the UTF-8 character set. (ANSI worked for us as well but it is saver to stay with UTF-8)

update the resource container


17. open the instrument options again

18. and this time update the resource container by simply creating it again


19. to do so just select the already existing resource container, which is the resources.nkr file.

20. and hit the save button. As already said this time your script txt gets automatically packed into the resources container (the nkr file).

apply the script to an empty script tab


21. now open the “Script Editor”

22. click on the edit button of an empty script tab to open it for editing

23. but instead of writing or pasting your script click “Apply From…”


24. select “…Resources Folder”

25. and select your script file.


26. finally hit the apply button the load and execute the script

That’s it.

making any changes / updates to the script File

this is very simply now since we can just open the script file from the Resources/Scripts folder without even starting Kontakt and start modifying our script. Next time we start Kontakt or hit the apply button again our changes will be applied.So we even don’t need to save the instrument (nki file).

IMPORTANT: however before publishing our instrument we have to update the resource container again. Otherwise our last updates with the script will not be packed into the nkr file.


How useful was this article?

something you didn't like? Please tell us before you rate!

Average rating / 5. Vote count:

No votes so far! Be the first to rate this post.

We are sorry that this post was not useful for you!

NOTE: highly negative votes may be removed without any reasonable given feedback!

Tell us how we can improve this post?

Leave a Reply

use <pre> </pre> to wrap code blocks

use <code> </code> to wrap small code snippets

use basic html to style your comment

Your email address will not be published. Required fields are marked *