Advanced Filters - Desktop

Advanced Filters - Desktop

Sep 30, 2025

NOTE: This version is outdated. Get the latest version here: https://buymeacoffee.com/utiltarian/extra-shop-filters


This bookmarklet has the following features:

  • Additional filtering options

  • (Improved) Categories filters, with an additional Textures section

  • A sort-wishlist-by-discount sort option

  • Purchased and missing Licenses filters to the Software filters

  • Interactive license highlighting on the store and product pages (NOTE: not currently working)

Note that there appears to be a bookmark character limit on mobile browsers, so on a mobile device, the work code is split into 2 bookmarklets. Visit the Advanced Filters - Mobile post for that instead.

To set up the bookmarklet:

  1. Create a bookmark for any page, give it whatever name you want.

  2. Copy the code below. If you want to have everything enabled, just replace the bookmark's URL with the below code, and you're done. Then, simply click the bookmark when you're on any shop page. Otherwise, to customize the functionality/options, continue to step 3:

javascript:(()=>{ const settings={
highlightLicenses:1,
useCategories:1,
wishlistDiscountSort:1,
autoSortWishlist:1,
saveOptions:1,
enableCopyIds:1,
filterOpts:[
[],
["owned","noDazPlus","noBundle","pa","do","nonFigure"],
["idRange","priceRange","noNew","onlyNew","cart"],
]};
if("www.daz3d.com"===location.host)try{const{filters:e,sorts:t,rawCategories:n,hasLoaded:i}=daz?.filter||{};if(i){const i=(e,t={},n="")=>{const i=document.createElement(e);for(let e in t)i.style[e]=t[e];return i.className=n,i},s=(e,t=document)=>t.querySelector(`[id=${e}]`),o=(e,t=document)=>t?.getElementsByClassName(e),a=(e,t=document)=>t?.getElementsByTagName(e),r=e=>[].slice.call(e),c=()=>{const e={set:void 0,filter:t=>e.set.has(t)};return e},l=e=>{const t=e.join(", "),n=`${e.length} IDs copied!`,i=document.createElement("textarea");i.value=t,document.body.appendChild(i),i.select(),setTimeout(()=>{document.execCommand("copy"),setTimeout(()=>{document.body.removeChild(i),alert(n),N()},10)},10)},{compat_figures:d,compat_software:p,shopCategories:u={},owned:h}=e,{highlightLicenses:f,useCategories:g,wishlistDiscountSort:y,autoSortWishlist:m,saveOptions:b,enableCopyIds:w,filterOpts:k}=settings,_=Object.keys(dazPricing),v=e=>a("input",e)?.[0],C=e=>Array.isArray(e)?e:"object"==typeof e?Object.keys(e).map(e=>parseInt(e)):DazFilter.prototype.unpackBuffer(e),x=(e,t)=>{if(!e?.length)return!1;for(let n=0;n<e.length;n++)if(!t.includes(e[n]))return!1;return!0},E=e=>e?.licenses?.includes("interactive")||!1,S=(e,t)=>{const n=window.loadedSlabs[e];n?n.then(e=>{e?t(E(e),e?.subProductIDs):t(null)}):t(null)},N=()=>{o("custom-alert-button")[0]?.focus()},I=(e,t,n)=>{const i=o("icon-row",e)[0];i&&(i.style.backgroundColor=n?"rgba(0,0,255,0.25)":t?"rgba(0,255,0,0.05)":"rgba(255,0,0,0.25)")},{interactive:O=[]}=daz.api.data["License/owned"].licensed;if(f){const e=()=>{const e=a("li");r(e).forEach(e=>{if(e.hasAttribute("data-productid")){const t=e.getAttribute("data-productid");S(t,(n,i)=>{null!==n&&I(e,n,O.includes(parseInt(t))||x(i,O))})}})};e()}const z=o("sku_number ")[0]?.innerText;if(z){if(f){const e=r(o("product_information")).map(e=>r(e?.children||[]).filter(e=>"bundle_info"===e.id)).filter(e=>e.length>0)[0]||[];if(e.length>0){const t=(e,t,n)=>{const s=i("input",{float:"right",position:"relative",zIndex:"989",marginTop:"30px",marginRight:"10px",marginBottom:"-50px",pointerEvents:"none"});s.type="checkbox",s.checked=n,e.insertBefore(s,e.firstChild)},{interactive:n}=daz.api.data["License/owned"].licensed;e.forEach(e=>{r(a("li",e)).forEach(e=>{const i=e.getAttribute("data-productid");if(null!==i){const s=parseInt(i),a=o("product-image",e)[0]||o("slab-link-img",e)[0];h[s]?n.includes(s)?(a.style.opacity=.25,t(e,a,!0)):S(i,n=>{n?(t(e,a,!1),a.style.opacity=.45):!1===n?a.style.opacity=.4:(a.style.opacity=.35,a.style.backgroundColor="red")}):S(i,n=>{n?t(e,a,!1):e.style.backgroundColor="rgba(255,0,0,0.5)"})}})})}}}else{const f="/wishlist"===location.pathname,x="/checkout/cart"===location.pathname,E=window.innerWidth<992,S=f?s(E?"collapsible-product-filters-container":"collapsible-product-display-container"):document;if(S&&!x){let x,N;if(f)N=s("large_owned",S)?.parentNode,x=N.parentNode;else{const e=s("slabs-container");e&&(x=i("div",{width:"100%",marginLeft:"3%"}),e.parentNode.insertBefore(x,e))}const I=f?"large_owned":"owned_check",O=f?"large_wishlist":"wishlist_check",z=f?"large_bundle":"bundle_check";if(x){if(!s("show_owned_only")){const A=f?daz.wishlistdisplay:daz.catalog,L=(e,t)=>{e.state=0;const n=[!1,!0,null];e.callback=()=>{t&&t(n[e.state])},e.addEventListener("click",t=>{t.ctrlKey||t.metaKey?e.state=2===e.state?0:2:e.state=e.state?0:1,e.checked=1===e.state,e.indeterminate=2===e.state,$(),e.callback()})},T=[];if(f){const e=i("div"),t=x;t.insertBefore(e,N),t.style.height="auto",t.style.marginBottom="20px",e.setAttribute("style",N.getAttribute("style")),N.removeAttribute("style"),e.appendChild(N),e.style.display="flex",e.style.flexDirection="column",o("desktop-sort-by")[0].style.marginLeft="auto",T.push(N)}const j=(e,t)=>{e&&e.checked!==t&&(e.checked=t,e.dispatchEvent(new Event("change")))},B=()=>{const e=f?T[0].parentNode:x,t=i("div",f&&E?{}:{marginBottom:"6px"},f?T[0].className:void 0);return f?e.insertBefore(t,T.at(-1).nextSibling):e.appendChild(t),T.push(t),t};let D=0;const P={},$=()=>{if(b){const e={};Object.keys(P).forEach(t=>{const[n,i]=P[t];e[t]=[n.indeterminate?2:n.checked?1:0],i&&e[t].push(i?.value)}),sessionStorage.setItem(`filters:${location.pathname}`,JSON.stringify({checks:e,sort:A.sortOrderSettings}))}},F=(e,t,n,s=null,o,a)=>{D++;const r=i("span",f?{}:{marginRight:"1em"},"cursor-pointer filter-checkbox"),c=i("label"),l=i("input"),d=i("span");let p;if(r.id=e,r.appendChild(c),c.appendChild(l),c.appendChild(d),d.innerText=` ${t}`,l.type="checkbox",a?L(l,()=>n(l.checked,l.indeterminate)):l.onchange=()=>n(l.checked),s||(s=T.at(-1)),s.appendChild(r),P[e]=[l],o){let t,n;if("object"==typeof o){const{label:e,size:s=100}=o;n=i("sup",{margin:"1em 0.5em"}),n.innerText=e,n.onclick=()=>{p.style.display="block",n.style.display="none"},r.appendChild(n),t=`${s}px`}else t="number"==typeof o?`${o}px`:"100px";p=i("input",{width:t,minWidth:"auto",marginTop:"-2px",marginBottom:"-4px",marginLeft:"6px",height:"28px",display:n?"none":""}),n&&(p.onkeydown=e=>{"Enter"===e.key&&(p.style.display="none",n.style.display="block")}),r.appendChild(p),r.style.display="inline-flex",P[e].push(p)}return{input:l,textField:p}},W=A?.productList?.map(e=>parseInt(e));let R;if(w){const e=i("sup",{margin:"1em 0.5em",cursor:"pointer"});e.innerText="[copy ids]",e.onclick=e=>{const t=(e.ctrlKey?W:A.ordered).slice().sort((e,t)=>e-t);l(t)};const t=o("amount_container")[0];t.style.display="flex",t.appendChild(e)}let M=[];const H=(e,t=!0)=>{const n=new Set;if("Set"===e?.constructor?.name)return t?new Set(_.map(e=>parseInt(e))).difference(e):e;const i=Array.isArray(e)?e:[e];let s={};return i.forEach(e=>{if(Array.isArray(e)||"object"!=typeof e){C(e).forEach(e=>{s[e]=!0})}else s={...s,...e}}),t?_.forEach(e=>{s[e]||n.add(parseInt(e))}):_.forEach(e=>{s[e]&&n.add(parseInt(e))}),n},J=()=>{R=W,M.forEach(({filter:e})=>{R=R.filter(e)}),A.productList=R,A.applyFilters(!0)},K=e=>{M=M.filter(t=>t!==e)},q=e=>f?U(e):o(e)[0],U=e=>v(s(e,S));let G=!0;const Q=(e,t,n,i,s=c(),o=void 0,a=[],r=!1)=>{const l=s;let d=[];const{input:p,textField:u}=F(e,t,async(e,t)=>{let s=G;G=!1;const c=()=>{l.update?.(),e||t?(d=[],a.forEach(e=>{const t=e.endsWith("_check")?q(e):U(e);t?.checked&&(r&&d.push(t),j(t,!1))}),M.push(l)):(d.forEach(e=>j(e,!0)),K(l)),J(),s&&($(),G=!0)};i?"function"==typeof n?n(e=>{l.set=e,c()},u.value):(l.filter=await l["updateFilter"+(t?"Alt":"")](u?.value,e),c()):(l.set||("function"==typeof n?n(e=>{l.set=e}):l.set=H(n,o)),c())},void 0,i,!!l.updateFilterAlt);return p},V=C(e.bundle.yes),X=t=>{const n=e=>{let t,n;return e.includes("-")?([t,n]=e.split("-").map(e=>parseInt(e)),isNaN(t)&&(t=0),isNaN(n)&&(n=1/0)):t=n=parseInt(e),e=>e>=t&&e<=n},i=e=>{const t=[],i=new Set;e.split(",").forEach(e=>{if(e.includes("-"))t.push(e);else{const t=parseInt(e.trim());isNaN(t)||i.add(t)}});const s=t.map(n);return i.size>0&&s.unshift(e=>i.has(e)),e=>s.some(t=>t(e))};switch(t){case"owned":Q("show_owned_only","Only Owned",h,!1,void 0,!1,[I,O],!0);break;case"noDazPlus":Q("hide_daz_plus","Hide Daz+",e.platClub.yes,!1,void 0,void 0,["large_platClub"]);break;case"pa":Q("hide_daz_original","PA Only",e.vendor["Daz Originals"],!1,void 0,void 0,["only_daz_original"]);break;case"do":Q("only_daz_original","DO Only",e.vendor["Daz Originals"],!1,void 0,!1,["hide_daz_original"]);break;case"noBundle":Q("hide_bundles","No Bundles",[V],!1,void 0,void 0,[z]);break;case"nonFigure":Q("hide_figure","Non-Figure",[].concat(...Object.keys(d).map(e=>d[e])));break;case"noNew":Q("no_new","Hide New",e.new.yes,!1,void 0,void 0,["only_new"]);break;case"onlyNew":Q("only_new","Only New",e.new.yes,!1,void 0,!1,["no_new"]);break;case"cart":const t=c();t.update=()=>t.set=new Set(daz.cart.cart?.products?.map(({id:e})=>e)||daz.api.data["Cart/contents"].products),t.update(),Q("in_cart","In Cart",null,!1,t,!1);break;case"idRange":Q("custom_id_range","ID Range",null,80,{updateFilter:(e,t)=>{const n=i(e);return e=>n(e)},updateFilterAlt:e=>{const t=i(e);return e=>!t(e)}});break;case"priceRange":Q("custom_price_range","Price Range",null,80,{updateFilter:e=>{const t=i(e);return e=>{const n=dazPricing[e];return t(n)}},updateFilterAlt:e=>{const t=i(e);return e=>{const n=dazPricing[e];return!t(n)}}})}},Y=e=>{const t=localStorage.getItem(e);return t&&JSON.parse(t)},Z=Y("__fullPrices")||{};f?k.forEach((e,t,n)=>{e.forEach(e=>X(e)),t!==n.length-1&&B()}):k.forEach((e,t,n)=>{e.length>0&&(B(),e.forEach(e=>X(e)))});const ee=(e,t,n,i)=>{const s=q(e);s&&(void 0!==n&&(s.checked=n),s.addEventListener("click",()=>{t.forEach(e=>{j(U(e),!1)}),i&&$()}),i&&s&&(P[i]=[s]))};f&&ee("large_platClub",["hide_daz_plus"]),ee(I,["show_owned_only"],A.filterSettings.owned,"hide_owned"),ee(O,["show_owned_only"],void 0,"wishlist"),ee(z,["hide_bundles"]);const te=async n=>{const s=document.querySelector("select[name=sort-by]");if(s){if(y){const o={};window.__discount=o;let a=!1;const r=async e=>{if(14548==e)return void(o[e]=-1);const t=dazPricing[e];let n=window.loadedSlabs[e];if(!n){if(void 0!==Z[e])return void(o[e]=Z[e]?Math.round(1e3*(1-t/Z[e])):1);n=fetch(`/dazApi/slab/${e}`).then(e=>e.json()),window.loadedSlabs[e]=n}const i=await n;if(i){const{prices:n,isDisabled:s}=i;if(!n||s)o[e]=-2;else{const i=parseInt(n.USD.replace(".",""));a||=Z[e]!==i,Z[e]=i,o[e]=Math.round(1e3*(1-t/Z[e]))}}},c=C(e.inWishlist),l=new Set(W),d=c.filter(e=>l.has(e)),p=new Set(d);if(d.length){const e=i("option");e.setAttribute("data-sortdata","wlpercentoff"),e.setAttribute("data-sortdir","1"),e.innerText="Wishlist % Off",s.appendChild(e);const[c,l]=A.sortOrderSettings,u=t[c]||t[Object.keys(t)[0]];await Promise.all(d.map(e=>r(e))),a&&(localStorage.setItem("__fullPrices",JSON.stringify(Z)),a=!1);const h=e=>void 0!==u[e]?u[e]:999999999-e*l,f=1==l?(e,t)=>h(e)-h(t):(e,t)=>h(t)-h(e),g=d.sort((e,t)=>o[t]-o[e]||f(e,t)),y=W.filter(e=>!p.has(e)).sort(f),b={};[...g,...y].forEach((e,t)=>{b[e]=t}),t.wlpercentoff=b,m&&(n=n||["wlpercentoff",1])}}if(n){const e=r(a("option",s)).findIndex(e=>e.getAttribute("data-sortdata")==n[0]&&e.getAttribute("data-sortdir")==n[1]);e>=0&&(s.selectedIndex=e,s.dispatchEvent(new Event("change")))}s.onchange=$}};if(g&&(()=>{let e,t,c=u;if(Object.keys(c).length>0&&"/shop"===location.pathname)localStorage.setItem("__shopCategories",JSON.stringify(c,(e,t)=>["children","products"].includes(e)?void 0:t));else if(c=Y("__shopCategories"),!c)return;const l=o("scroll-container",s("shopCategoriesList"))?.[0];if(l)t=i(l.tagName,{},l.className),l.hasAttribute("style")&&t.setAttribute("style",l.getAttribute("style")),l.replaceWith(t);else{const n=f?o("product-filter-section")[0]:r(o("product-filter-section")).find(e=>"artists"===e.getAttribute("data-filter-group"));if(!n)return;const s=i(n.tagName,{},n.className);s.innerHTML=n.innerHTML,n.parentNode.insertBefore(s,n),[e,t]=s.children,f?a("h4",e)[0].innerText="Categories":o("filter-section-title",e)[0].innerText="Categories";let c=!1;e.onclick=()=>{const[n,i]=c?["none","block"]:["block","none"];o("fd-plus",e)[0].style.display=i,t.style.display=o("fd-minus",e)[0].style.display=n,c=!c},t.id="__CustomCategories",t.innerText=""}const d=i("ul");t.appendChild(d);let p,h,g=!1,y=[],m=[];const b=e=>{let t=e[0];for(let n=1;n<e.length;n++)t=t.union(e[n]);return t},w={filter:e=>(!p||p.has(e))&&(!h||!h.has(e))},k={},_=(e,t)=>{if(k[e])return k[e];const{products:i=[],children:s=[]}=n[e]||{};let o=new Set(C(i));return s.forEach(e=>{o=o.union(_(e))}),t&&(o=o.difference(t)),k[e]=o,o},v=(e,t,n,s)=>{const o=i("li",{},"filter_visible js-filter-option-container"+(n?"":" bs5-ps-3")),a=i("label",{},"cursor-pointer item-label"),r=i("input");r.type="checkbox",r.id=e;const c=i("span",{},"idx");return o.appendChild(a),a.appendChild(r),a.appendChild(c),c.innerText=t,P[e]=[r],L(r,t=>{const n=_(e);t?(y.push(n),p=b(y)):null===t?(y=y.filter(e=>e!==n),p=b(y),m.push(n),h=b(m)):(y=y.filter(e=>e!==n),p=b(y),m=m.filter(e=>e!==n),h=b(m)),p||h?g||(g=!0,M.push(w)):(g=!1,K(w)),J()}),s.appendChild(o),o};let x=-100;const E={id:x},S=[];n[x]={children:S};const N=new Set(V),I=[];Object.keys(n).forEach(e=>{const{name:t}=n[e];/texture/i.test(t)&&(n[--x]=n[e],S.push(x),I.push({id:x,name:t}),_(x,N))}),E.childrenInfo=I.sort((e,t)=>e.name.localeCompare(t.name));let O=new Set(W);const z=e=>O.intersection(_(e)).size,A=(e,{id:t,childrenInfo:n=[]})=>{const i=z(t);if(i){const s=v(t,`${e} (${i})`,!0,d);n.forEach(({id:e,name:t,products:n})=>{const i=n||z(e);i&&v(e,`${t} (${i})`,!1,s)})}};let T=!1;Object.keys(c).forEach(e=>{e>"Textures"&&!T&&(T=!0,A("Textures",E)),A(e,c[e])})})(),W){const e=e=>{let t="";return e.forEach(e=>{let n=127&e;for(e>>=7;e>0;)t+=String.fromCharCode(128|n),n=127&e,e>>=7;t+=String.fromCharCode(n)}),btoa(t)},{"3dprinting":t=[],interactive:n=[]}=window.daz?.api?.data?.["License/owned"]?.licensed,i=new Set(n),s=new Set(t),o=W.filter(e=>!i.has(e)),a=W.filter(e=>!s.has(e));p["Missing Interactive License"]=e(o),p["Owned Interactive License"]=e(n.map(e=>parseInt(e))),p["Missing 3d Print License"]=e(a),p["Owned 3d Print License"]=e(t.map(e=>parseInt(e)))}let ne,ie;if(r(o("hideable-product-filters")).forEach(e=>e.classList.contains("filter-checkboxes")?ne=e:ie=e),ne&&ie){const e=()=>{window.innerWidth<992?(ne.style.setProperty("display","block","important"),ie.style.marginTop=`${26+ne.clientHeight}px`,ne.style.display=""):ie.style.marginTop=""};["max-width:576","min-width:992"].forEach(t=>window.matchMedia(`(${t}px)`).addEventListener("change",e)),e()}const se=b&&sessionStorage.getItem(`filters:${location.pathname}`);let oe;if(se){const{checks:e,sort:t}=JSON.parse(se);oe=t,Object.keys(P).forEach(t=>{const[n,i]=P[t],[s=0,o=""]=e[t]||[];if(n.state=s,i&&(i.value=o),2===s)n.indeterminate=!0;else{const e=1===s;if(e===n.checked)return;n.checked=e}n.dispatchEvent(new Event("change")),n.callback?.()})}te(oe)}}}else if(w&&x){const e=s("items-container"),t=r(o("item-container",e)).map(e=>o("item-image",e)[0].src.match(/\.com\/p\/(\d+)\//)[1]);t?.length>0&&l(t.sort((e,t)=>e-t))}}}}catch(e){console.log("error",e)} })()

3. To adjust the features, you will need to change the lines at the start of the code. For the following items, change the 1 to a 0 if you want to turn off the feature. For example, to disable license highlighting, you would want the line to be: highlightLicenses:0,

  • highlightLicenses - controls whether interactive licenses are highlighted green/red, and whether bundle product pages show license indicators

  • useCategories - controls whether to inject the Categories filters section into every page (note: you'll need to run the bookmarklet on the homepage once for this to work on other pages)

  • wishlistDiscountSort - controls whether to add a sort-by-wishlist-discount sort option

  • autoSortWishlist - controls whether to automatically set the sort to the wishlist discount sort upon running the bookmarklet. If this option is disabled, the sort will be added, but it won't automatically change the sort setting

  • saveOptions - controls whether to save your filtering and sort options (to sessionStorage) so that when you return to the same page in the same tab, your previous settings will be restored

  • enableCopyIds - adds a button to copy all ids on the current page. Regular click copies just the filtered ids, ctrl+click copies all ids, including the filtered ones

4. To change which filter options appear, or their order, you want to edit these lines:

[],
["owned","noDazPlus","noBundle","pa","do","nonFigure"],
["idRange","priceRange","noNew","onlyNew","cart"],

The first set of brackets being empty means no additional filtering options are added to the first row of filters (i.e. the filters built into the site). Though you can't edit the order of the default site checkmarks either, if you want to add more options to the first row, you can do so by moving them to the first set of brackets.

To remove a filter option, you can just delete it. To change the order, just change the sequence of the comma-separated values. Make sure each value remains in quotes, they're separated by commas, and don't change the capitalization. Description of each:

  • "owned" - Only show owned items

  • "noDazPlus" - Hide Daz+

  • "noBundle" - Hide Bundles

  • "pa" - Published Artist items only (i.e. non-Daz Originals)

  • "do" - Daz Original items only (no PA items)

  • "nonFigure" - Hides items assigned to any of the Figure categories

  • "idRange" - Lets you filter using a min/max product id range. Example: "20000-50000"

  • "priceRange" - Lets you filter using a min/max price range (uses the sale price, not the full price). Prices should be specified in cents, no dollar sign. Example (for between $5 and $10): "500-1000"

  • "noNew" - Hide new items

  • "onlyNew" - Only show new items

  • "cart" - Show items in your cart

As an example, lets say you want a minimal setup where you have the Only Owned option in the first row (alongside the site's default options), and then only have a Hide Daz+, DO Only, and Hide New option. You would change those lines to:

["owned"],
["noDazPlus","do","noNew"],

5. Once configured to your liking, copy the full text to your bookmark's URL, and run on any shop page.

And, if you have the license highlighting enabled, you can re-run the bookmarklet as new products load in to show whether they have a license or not.

Enjoy!

Enjoy this post?

Buy Utiltarian a coffee

More from Utiltarian

PrivacyTermsReport