How to Make a Clip Command on Twitch
In this article
To make a clip command on Twitch, you need to use a third-party chat bot like Nightbot, StreamElements, or Fossabot—Twitch itself does not let you create custom chat commands. The command lets viewers type something like !clip in chat, and the bot automatically creates a clip of the last 30 seconds of your stream. This guide walks you through setting it up with Nightbot, the most popular free option.
What You'll Need
- A Twitch account with the ability to create clips (any account can create clips, but you need to be the streamer or a moderator/editor for the channel).
- A Nightbot account (free) connected to your Twitch channel.
- Your channel must have clips enabled in Twitch settings (they are enabled by default).
Step-by-Step
- Connect Nightbot to your Twitch channel. Go to
nightbot.tvand click "Login with Twitch." Authorize Nightbot to join your chat and manage your channel. Once connected, Nightbot will automatically join your chat as a bot. - Open the Nightbot dashboard. After logging in, click on your profile icon in the top-right and select "Dashboard." You'll land on the main control panel.
- Go to the custom commands section. In the left sidebar, click "Commands," then "Custom." This is where you'll create your clip command.
- Create a new command. Click the "Add Command" button (or the plus icon). A form will appear.
- Set the command name. In the "Command" field, type
!clip(without the quotes). This is what viewers will type in chat. - Set the bot's response. In the "Message" field, enter the following exactly:
$(twitch.clip $(channel))
This is Nightbot's built-in variable that creates a clip of the last 30 seconds and posts the link in chat. You can add extra text around it, like "Here's your clip: $(twitch.clip $(channel))" but the variable is essential. - Choose who can use the command. In the "User Level" dropdown, select "Everyone" so any viewer can use it. If you want to restrict it to regulars or subscribers, pick that option instead.
- Set a cooldown (optional but recommended). In the "Cooldown" field, set a number of seconds (e.g., 30) to prevent spam. This means each viewer can only use the command once every 30 seconds.
- Save the command. Click the "Submit" or "Save" button. Your command is now live.
- Test it. In your Twitch chat, type
!clip(as a viewer or in your own chat). The bot should respond with a clip link. If it doesn't, check the troubleshooting section below.
Common Mistakes
- Using the wrong variable. Some bots use different syntax. For Nightbot, it's
$(twitch.clip $(channel)). For StreamElements, it's${twitch.clip}. Using the wrong one will fail. - Not enabling clips on Twitch. If clips are disabled in your Twitch settings, the bot can't create them. Go to your Twitch Creator Dashboard > Settings > Stream, and make sure "Store past broadcasts" and "Create clips" are enabled.
- Bot not in chat. If Nightbot isn't in your chat, the command won't work. Check that you've connected it properly and that it's not banned or timed out.
- Cooldown too low. If you set a cooldown to 0, viewers can spam the command, which might trigger Twitch's rate limits and cause the bot to fail silently.
- Typing the command with a space. Make sure the command is exactly
!clipwith no spaces. If you type! clip, it won't work.
Tips
- Add a custom response. Instead of just the link, you can make the bot say something fun like "$(twitch.clip $(channel)) — clip created!" to make it more engaging.
- Use a longer cooldown for everyone. A 30-60 second cooldown prevents spam while still letting multiple people clip during a big moment.
- Consider a second command for moderators. Create another command like
!clipmodwith a shorter cooldown (or none) and set the user level to "Moderator" so your mods can clip quickly without waiting. - Promote the command. Mention it on your stream overlay or in your chat rules so viewers know it exists.
- Check your clip settings. In your Twitch dashboard, you can set who can clip (everyone, followers, subscribers, etc.). Make sure it matches your intent.
Troubleshooting
If the command doesn't work, follow these steps in order:
- Check the bot's response. If Nightbot responds with an error message like "Error creating clip," it's usually a permissions issue. Make sure your Twitch account has clips enabled and that you're not in a stream that has clips disabled.
- Verify the variable syntax. Go back to your command and ensure you typed
$(twitch.clip $(channel))exactly. A missing parenthesis or a typo will break it. - Restart the bot. Sometimes Nightbot gets stuck. In your Twitch chat, type
!nightbotand then!nightbot restart(if you have the right permissions). This reconnects the bot. - Check if Nightbot is banned or timed out. Look at your chat moderation list. If Nightbot is banned, unban it. If it's timed out, wait or manually remove the timeout.
- Test with a different viewer. Some viewers might have their own Twitch settings that prevent clips, but that's rare. Ask a friend to try it.
- Switch to StreamElements or Fossabot. If Nightbot still fails, try another bot. For StreamElements, the command is
!clipwith response${twitch.clip}. For Fossabot, it's$(twitch.clip $(channel))as well.
Frequently Asked Questions
Can I make a clip command without a bot?
No. Twitch does not have a built-in command system for viewers to create clips. You need a third-party bot like Nightbot, StreamElements, or Fossabot.
Does the clip command work for any streamer or only me?
It works for any streamer whose channel the bot is connected to. If you're a moderator in someone else's channel, you can connect Nightbot there too, but the command will create clips for that channel.
What if I want the clip to be longer than 30 seconds?
Twitch clips are always 30 seconds long by default. You cannot change the length via a bot command. You can edit the clip afterward in the Clip Manager to extend it up to 60 seconds, but the bot will always create a 30-second clip.
Can viewers use the command if they don't have a Twitch account?
No. They must be logged into Twitch to send chat messages, so they need an account.
Will the clip command work if I'm streaming in a category that doesn't allow clips?
Some categories (like music or certain licensed content) may have clips disabled by Twitch. If that's the case, the bot will return an error. You can't override this.
How do I remove the clip command?
Go to Nightbot dashboard > Commands > Custom, find your !clip command, and click the trash icon to delete it.