CSS Cursor: All Values, Custom Cursors and Opacity

The cursor property sets the mouse pointer shown over an element, for example cursor: pointer for clickable things, not-allowed for disabled controls and grab for draggable items. Custom cursors use url() with an image, optional hotspot coordinates and a required keyword fallback. Hover each tile below to see all 36 standard values in your browser.

The cursors you will use most
StateCSSTailwind
Link or buttoncursor: pointercursor-pointer
Disabled controlcursor: not-allowedcursor-not-allowed
Can be dragged / draggingcursor: grab / grabbingcursor-grab / cursor-grabbing
Editable textcursor: textcursor-text
Resize a columncursor: col-resizecursor-col-resize
Busy but usablecursor: progresscursor-progress

Updated

Cursor names are easy to guess wrong, and each operating system draws them a little differently. This gallery lets you hover every keyword in your own browser, then shows how to make a custom image cursor that still falls back gracefully, plus the matching opacity tricks for faded and disabled states.

All 36 cursor values

Standard cursor keywords (CSS Basic User Interface Level 4); Tailwind classes are cursor-<value>
ValueGroupMeaning
autoGeneralBrowser decides from context
defaultGeneralThe platform arrow
noneGeneralNo cursor drawn
context-menuLinks and statusA context menu is available
helpLinks and statusHelp is available
pointerLinks and statusA link or clickable control
progressLinks and statusBusy, but you can still interact
waitLinks and statusBusy, cannot interact yet
cellSelectionA table cell or cells can be selected
crosshairSelectionPrecise two-dimensional selection
textSelectionText can be selected or edited
vertical-textSelectionVertical text can be selected
aliasDrag and dropA shortcut or alias will be made
copyDrag and dropSomething will be copied
moveDrag and dropSomething will be moved
no-dropDrag and dropCannot drop here
not-allowedDrag and dropThe action is not allowed
grabDrag and dropCan be grabbed and dragged
grabbingDrag and dropCurrently being dragged
all-scrollResize and scrollCan scroll in any direction
col-resizeResize and scrollResize a column horizontally
row-resizeResize and scrollResize a row vertically
n-resizeResize and scrollMove the top edge
e-resizeResize and scrollMove the right edge
s-resizeResize and scrollMove the bottom edge
w-resizeResize and scrollMove the left edge
ne-resizeResize and scrollMove the top right corner
nw-resizeResize and scrollMove the top left corner
se-resizeResize and scrollMove the bottom right corner
sw-resizeResize and scrollMove the bottom left corner
ew-resizeResize and scrollResize left or right
ns-resizeResize and scrollResize up or down
nesw-resizeResize and scrollResize along the rising diagonal
nwse-resizeResize and scrollResize along the falling diagonal
zoom-inZoomCan zoom in
zoom-outZoomCan zoom out

Custom cursor with hotspot and fallback

Inline SVG ring cursor centred on its hotspot

The 12 12 hotspot puts the click at the ring's centre. crosshair is used if the image is not accepted.

<style>
  .area { height: 110px; display: grid; place-items: center; background: #f1f5f9; border-radius: 12px;
          cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24'%3E%3Ccircle cx='12' cy='12' r='9' fill='none' stroke='%234F98FB' stroke-width='3'/%3E%3C/svg%3E") 12 12, crosshair; }
</style>
<div class="area">Move the mouse over this area</div>

Disabled, drag and resize states

Cursors that match the interaction

Hover each element. The draggable card switches to grabbing while the mouse button is held.

<style>
  button { padding: 8px 14px; margin: 4px; cursor: pointer }
  button:disabled { opacity: .5; cursor: not-allowed }
  .card { display: inline-block; padding: 12px; margin: 4px; background: #dbeafe; border-radius: 10px; cursor: grab; user-select: none }
  .card:active { cursor: grabbing }
  .panel { resize: horizontal; overflow: auto; width: 180px; min-width: 120px; padding: 8px; border: 1px solid #94a3b8; margin-top: 8px }
  .split { display: inline-block; width: 8px; height: 40px; background: #cbd5e1; cursor: col-resize; vertical-align: middle }
</style>
<button>Save</button><button disabled>Publish</button>
<div class="card">Drag me</div> <span class="split" title="Column divider"></span>
<div class="panel">Drag the corner to resize this panel</div>

opacity vs visibility vs rgba

Choosing how to fade
TechniqueAffects children?Still clickable?Animates smoothly?Tailwind
opacity: 0.5Yes, everything insideYesYesopacity-50
visibility: hiddenYes (children can opt back in)NoSwitches instantlyinvisible
background: rgb(0 0 0 / 0.5)No, only that layerYesYesbg-black/50
color: rgb(17 17 17 / 0.6)No, only the textYesYestext-black/60

Whole-element opacity next to a translucent background

The left banner fades its text along with the box. The right one keeps crisp text over a see-through background.

<style>
  .bg { display: flex; gap: 10px; padding: 14px; background: linear-gradient(90deg, #f59e0b, #ec4899); border-radius: 12px }
  .bg div { flex: 1; padding: 14px; color: #fff; font-weight: 600 }
</style>
<div class="bg">
  <div style="background: #000; opacity: .5">opacity: .5</div>
  <div style="background: rgb(0 0 0 / .5)">rgb(0 0 0 / .5)</div>
</div>

Cursors are hints, not controls

The cursor tells mouse users what will happen before they click. A pointer promises a click target, a text cursor promises selectable or editable text, and a resize arrow promises dragging. Showing a pointer on something that does nothing is a broken promise.

Keyboard, touch and screen reader users never see these hints. Interactive things still need to look interactive, have a visible focus style, and use real buttons and links so their role is announced.

Custom image cursors that do not break

A cursor image is fetched like any other image, so a slow or failed download leaves the fallback keyword in place. An inline data: SVG avoids the request entirely and stays crisp on high density screens.

The hotspot is the exact pixel that clicks. For an arrow it is the tip, usually near 0 0; for a crosshair or circle it is the centre. A wrong hotspot makes clicks land a few pixels away from where people aim.

Fading things out properly

For a disabled look, combine opacity around 0.5 with cursor: not-allowed and the disabled attribute. Check that the faded text still meets contrast requirements if people need to read it.

For hover reveals, animate opacity because it is cheap to render, and pair it with visibility so the element cannot be clicked while transparent. A colour with an alpha channel is the right tool when only one layer, such as a background or border, should be translucent.

How it works

  1. Hover any tile in the gallery to see that cursor as your system draws it. Click a tile to copy its declaration.
  2. Use the filter to narrow the list to links, resizing, dragging or status cursors.
  3. Open the custom cursor builder, adjust the hotspot and test the result in the target area.
  4. Read the opacity section to choose between opacity, visibility and rgba colours for fades.

Tips

Frequently asked questions

How do I make a custom cursor in CSS?

Write cursor: url(cursor.svg) 4 4, auto; where the image is a small PNG, SVG or CUR file, the two numbers are the hotspot in pixels from the top left, and auto is the fallback keyword used if the image fails. You can list several url() images before the keyword.

Which cursor should a disabled button show?

not-allowed is the usual choice. Target it with button:disabled { cursor: not-allowed; opacity: 0.5; } and keep the real disabled attribute, so keyboard and screen reader users are told the control is unavailable, not just mouse users.

What is the difference between opacity and visibility?

opacity fades the whole element, including children, and a fully transparent element still receives clicks and focus. visibility: hidden switches the element off for both pointer and assistive technology while keeping its space. Use opacity for the fade itself and switch visibility at the end so invisible items cannot be clicked.

Why does opacity make my text transparent too?

opacity applies to everything inside the element. To make only the background see-through, use a translucent colour instead: background-color: rgb(0 0 0 / 0.5), or the older rgba(0, 0, 0, 0.5). The text stays fully opaque.

Can I hide the cursor?

cursor: none hides it over the element, which games, kiosks and video players sometimes need. Use it sparingly on ordinary websites, because people lose track of where they are pointing.

Related: CSS transitions playground, CSS box model and display, Colour contrast checker, Website accessibility checklist, CSS selectors cheat sheet.

Start for free or see all free tools. We.Inc is free to start, with no card needed. AI building is on paid plans from $20 a month.

More in Guides

We.Inc is an AI-powered website builder you can resell under your own brand. Launch a branded client dashboard, bill on Stripe Connect, and deliver AI-generated websites in minutes. White-label plans start at $99 a month for 25 client sites, with a 7-day free trial and no per-site fees.

Product

Who It's For

Features

Resources

Company

View Sitemap