Userscripts / Customization

ArmadilloEater

French Taunter
In this thread we list, propose and discuss custom scripts and other custom content linked to Derpibooru.
 
Note that this is not meant to replace the Feature suggestion thread, if anything it’s a complement. If you have any ideas, or have created userscripts you would like to add to this list, please post about them here. We will add links to the relevant threads / repositories, with credits to the authors, and short descriptions. Once a script has a dedicated thread, try to keep the relevant discussion there, to give room for new ideas / discussions.
 
The scripts listed in this post are not official Derpibooru content, their inclusion doesn’t necessarily mean we support it, and the site cannot be held responsible for the possible harm they may cause. Always be careful about the scripts you download, please report any abuse to the staff, and when in doubt don’t hesitate to ask other users / developers.
 
 
Sei
Wallet After Summer Sale -

Pretext Hyperprocessor
Derpi-Notify and Derpi-NewTab are both individual browser extensions, I would suggest sorting those under a separate category from Userstyles and Userscripts.
Marker
My Little Pony - 1992 Edition
Wallet After Summer Sale -
Magnificent Metadata Maniac - #1 Assistant
Not a Llama - Happy April Fools Day!

Misanthrope
Oh I love the idea of this thread!
 
I see one of my script is listed twice, “Derpibooru-User-Blocker” and “User Blocker” are actually the same thing.
 
Also, would this thread be a good place to post any scripts for extremely minor tweaks that I don’t think is worth starting a thread for?
Marker
My Little Pony - 1992 Edition
Wallet After Summer Sale -
Magnificent Metadata Maniac - #1 Assistant
Not a Llama - Happy April Fools Day!

Misanthrope
So I’ve gotten a little tired of doing this little dance…  
full  
…whenever I’m trying to click on a tag in the middle of the tag soup, here’s a dirty, hacky way of adding half a second of delay to the dropdown using CSS:
 
`.tag.dropdown .dropdown__content {
display: block;
overflow-y: hidden;
max-height: 0vh;
padding: 0px;
transition: max-height 0s, padding 0s;
}
.tag.dropdown:hover .dropdown__content {
transition-delay: 0.5s;
max-height: 100vh;
padding: 5px;
}`
stsyn
Nightmare in the Moon - Had their OC in the 2024 Derpibooru Collab.
Lunar Supporter - Helped forge New Lunar Republic's freedom in the face of the Solar Empire's oppressive tyrannical regime (April Fools 2023).
Elements of Harmony - Had an OC in the 2022 Community Collab
Non-Fungible Trixie -
Twinkling Balloon - Took part in the 2021 community collab.
Notoriously Divine Tagger - Consistently uploads images above and beyond the minimum tag requirements. And/or additionally, bringing over the original description from the source if the image has one. Does NOT apply to the uploader adding several to a dozen tags after originally uploading with minimum to bare tagging.
Best Artist - Providing quality, Derpibooru-exclusive artwork
Fine Arts - Two hundred uploads with a score of over a hundred (Safe/Suggestive)
Economist -
Cool Crow - "Caw!" An awesome tagger

Moderator
Note that this action will reduce security of the site and may allow inserting of malicious content! Do this only at your own risk.
 
Since Derpibooru enforced CSP to disallow usage of <style> tags, for correct working of some userscript and userstyles, you have to do some one-time preparings:  
Firefox: see there  
Chrome and chromium based: install  
Content Security Policy Override (this shit is glitching, you may need to reinstall it few times later, but I don’t know anything better)  
and type
 
\[ \["https://\(www\\\\.\|\)\(trixie\|derpi\)booru.org/", \[ \["style-src", "style-src 'unsafe-inline'"\] \]\] \]
 
Like this  
full
Sollace
Lunar Champion - Led the charge of major battles for the New Lunar Republic, bringing swift and crushing defeat to the forces of the Solar Empire (April Fools 2023).
Elements of Harmony - Had an OC in the 2022 Community Collab
Non-Fungible Trixie -
Verified Pegasus - Show us your gorgeous wings!
Preenhub - We all know what you were up to this evening~
My Little Pony - 1992 Edition
Notoriously Divine Tagger - Consistently uploads images above and beyond the minimum tag requirements. And/or additionally, bringing over the original description from the source if the image has one. Does NOT apply to the uploader adding several to a dozen tags after originally uploading with minimum to bare tagging.
A Really Hyper Artist - 500+ images under their artist tag
Wallet After Summer Sale -
Friendship, Art, and Magic (2019) - Celebrated Derpibooru's seventh year anniversary with friends

I am the night!
@Mildgyth  
What he has there shouldn’t be a huge problem. Malicious styles can’t do much though they can change the layout and appearance of the site.
 
Worst comes to worst, a malicious userstyle can use backgroun-image in custom css to trigger web requests to track user behaviour.
Marker
My Little Pony - 1992 Edition
Wallet After Summer Sale -
Magnificent Metadata Maniac - #1 Assistant
Not a Llama - Happy April Fools Day!

Misanthrope
I’m currently looking into if the GM_addStyle API could be used to get around the policy. Doesn’t look very promising, unfortunately. Other than Greasemonkey’s lack of support for it, I couldn’t get it to work on Firefox’s Tampermonkey (or Violentmonkey) either.
Background Pony #D9B6
StSyaN  
Alternative for Firefox?
 
Since Derpibooru enforced CSP to disallow usage of <style> tags
Not only <style> tags, even inline styles are blocked.
 
It’s real pity. This is going to result in loss of userscipts userbase. Only stubborn people will install two extensions for just one userscript. All for sake of vague security.
Sollace
Lunar Champion - Led the charge of major battles for the New Lunar Republic, bringing swift and crushing defeat to the forces of the Solar Empire (April Fools 2023).
Elements of Harmony - Had an OC in the 2022 Community Collab
Non-Fungible Trixie -
Verified Pegasus - Show us your gorgeous wings!
Preenhub - We all know what you were up to this evening~
My Little Pony - 1992 Edition
Notoriously Divine Tagger - Consistently uploads images above and beyond the minimum tag requirements. And/or additionally, bringing over the original description from the source if the image has one. Does NOT apply to the uploader adding several to a dozen tags after originally uploading with minimum to bare tagging.
A Really Hyper Artist - 500+ images under their artist tag
Wallet After Summer Sale -
Friendship, Art, and Magic (2019) - Celebrated Derpibooru's seventh year anniversary with friends

I am the night!
@ArmadilloEater  
Please do not direct users to install tampermonkey. It’s not safe to use.
 
Firefox users should switch to Violentmonkey and uninstall Tampermonkey immediately.
 
Likewise do not use Stylish, switch to Stylus .
 
Both of the addons are known to collect browsing data without the user’s consent.
byte[]
Solar Supporter - Fought against the New Lunar Republic rebellion on the side of the Solar Deity (April Fools 2023).
Non-Fungible Trixie -
Verified Pegasus - Show us your gorgeous wings!
Preenhub - We all know what you were up to this evening~
An Artist Who Rocks - 100+ images under their artist tag
Artist -

Philomena Contributor
@Background Pony #0890  
This is a site with user-submitted content. As a developer, I would much prefer to keep that content as tightly constrained as is literally possible. It is not for a “sake of vague security”, it is defense in depth.
stsyn
Nightmare in the Moon - Had their OC in the 2024 Derpibooru Collab.
Lunar Supporter - Helped forge New Lunar Republic's freedom in the face of the Solar Empire's oppressive tyrannical regime (April Fools 2023).
Elements of Harmony - Had an OC in the 2022 Community Collab
Non-Fungible Trixie -
Twinkling Balloon - Took part in the 2021 community collab.
Notoriously Divine Tagger - Consistently uploads images above and beyond the minimum tag requirements. And/or additionally, bringing over the original description from the source if the image has one. Does NOT apply to the uploader adding several to a dozen tags after originally uploading with minimum to bare tagging.
Best Artist - Providing quality, Derpibooru-exclusive artwork
Fine Arts - Two hundred uploads with a score of over a hundred (Safe/Suggestive)
Economist -
Cool Crow - "Caw!" An awesome tagger

Moderator
@Sollace  
I imaging possibility of using ::after to create a window, which completely blocks Derpibooru and says “pay X to Y to unlock this site”. Tracking that way probably will be impossible because of untouched part of CSP.
 
@Background Pony #0890  
As byte[] says, using elem.style.prop = x instead of elem.style = “prop:x” bypasses issue.
 
@Sollace  
Last time I tried Violentmonkey, it didn’t work with Derpibooru at all. Maybe stuff changed, though.
stsyn
Nightmare in the Moon - Had their OC in the 2024 Derpibooru Collab.
Lunar Supporter - Helped forge New Lunar Republic's freedom in the face of the Solar Empire's oppressive tyrannical regime (April Fools 2023).
Elements of Harmony - Had an OC in the 2022 Community Collab
Non-Fungible Trixie -
Twinkling Balloon - Took part in the 2021 community collab.
Notoriously Divine Tagger - Consistently uploads images above and beyond the minimum tag requirements. And/or additionally, bringing over the original description from the source if the image has one. Does NOT apply to the uploader adding several to a dozen tags after originally uploading with minimum to bare tagging.
Best Artist - Providing quality, Derpibooru-exclusive artwork
Fine Arts - Two hundred uploads with a score of over a hundred (Safe/Suggestive)
Economist -
Cool Crow - "Caw!" An awesome tagger

Moderator
@Sollace  
Is there any info about collecting user data by Tampermonkey? Rough googling gave me nothing.
 
UPD: I only managed to find info about inserted Google Analytics, and I find it a little weird to worry about it, if use Google browser…
Interested in advertising on Derpibooru? Click here for information!
Champions of Equestria

Help fund the $15 daily operational cost of Derpibooru - support us financially!

Syntax quick reference: **bold** *italic* ||hide text|| `code` __underline__ ~~strike~~ ^sup^ %sub%

Detailed syntax guide