Skip to content

Claymorphism Button

Soft, puffy clay-like surfaces with thick shadows and rounded blobs

Claymorphism Button

by FreeCsStyles Dev's

Soft UIClaymorphism
🌐🎨⚛️💚🅰️🔥☁️
#clay#puffy#soft#playful#friendly#3d

Embed this component

Paste this snippet into any site — the design renders in a sandboxed iframe served from /embed/claymorphism.

<iframe src="/embed/claymorphism" sandbox="allow-scripts" loading="lazy" title="Claymorphism Button" style="border:0;width:100%;height:480px;overflow:hidden"></iframe>

Implementation code

Copy the HTML and CSS for Claymorphism Button, or grab a framework-specific implementation. The HTML and CSS variants are self-contained; framework variants assume that framework's project setup.

HTML
<button class="clay-button">Clay Button</button>
CSS
.clay-button {
  padding: 1rem 2rem;
  border-radius: 1rem;
  background: linear-gradient(180deg, rgba(255,255,255,0.12), rgba(255,255,255,0.04));
  color: #f1f5f9;
  font-weight: 600;
  border: 1px solid rgba(255,255,255,0.1);
  cursor: pointer;
  box-shadow: inset 0 -3px 6px rgba(0,0,0,0.2), 0 6px 12px rgba(0,0,0,0.3);
  transition: all 0.2s ease;
}

.clay-button:hover {
  transform: scale(1.04);
  box-shadow: inset 0 -4px 8px rgba(0,0,0,0.2), 0 10px 20px rgba(0,0,0,0.35);
}

.clay-button:active {
  transform: scale(0.97);
  box-shadow: inset 0 2px 4px rgba(0,0,0,0.25);
}
Tailwind CSS
<button class="px-8 py-4 rounded-2xl font-semibold bg-gradient-to-b from-white/12 to-white/4 text-white border border-white/10 shadow-[inset_0_-3px_6px_rgba(0,0,0,0.2),0_6px_12px_rgba(0,0,0,0.3)] hover:scale-104 hover:shadow-[inset_0_-4px_8px_rgba(0,0,0,0.2),0_10px_20px_rgba(0,0,0,0.35)] active:scale-97 active:shadow-[inset_0_2px_4px_rgba(0,0,0,0.25)] transition-all">
  Clay Button
</button>
React
function ClayButton() {
  return (
    <motion.button
      className="px-8 py-4 rounded-2xl font-semibold border border-white/10"
      style={{
        background: 'linear-gradient(180deg, rgba(255,255,255,0.12), rgba(255,255,255,0.04))',
        color: '#f1f5f9',
        boxShadow: 'inset 0 -3px 6px rgba(0,0,0,0.2), 0 6px 12px rgba(0,0,0,0.3)',
      }}
      whileHover={{ scale: 1.04, boxShadow: 'inset 0 -4px 8px rgba(0,0,0,0.2), 0 10px 20px rgba(0,0,0,0.35)' }}
      whileTap={{ scale: 0.97 }}
      transition={{ type: 'spring', stiffness: 300, damping: 15 }}
    >
      Clay Button
    </motion.button>
  );
}
LWC — HTML template
<template>
  <button class="clay-button" onclick={handleClick}>
    <slot>Clay Button</slot>
  </button>
</template>
LWC — JavaScript
import { LightningElement, api } from 'lwc';
export default class ClayButton extends LightningElement {
  @api label = 'Clay Button';
  handleClick() {
    this.dispatchEvent(new CustomEvent('buttonclick', { bubbles: true, composed: true }));
  }
}
LWC — CSS
.clay-button { padding: 1rem 2rem; border-radius: 1rem; background: linear-gradient(180deg, rgba(255,255,255,0.12), rgba(255,255,255,0.04)); color: #f1f5f9; font-weight: 600; border: 1px solid rgba(255,255,255,0.1); cursor: pointer; box-shadow: inset 0 -3px 6px rgba(0,0,0,0.2), 0 6px 12px rgba(0,0,0,0.3); transition: all 0.2s ease; }
.clay-button:hover { transform: scale(1.04); box-shadow: inset 0 -4px 8px rgba(0,0,0,0.2), 0 10px 20px rgba(0,0,0,0.35); }
.clay-button:active { transform: scale(0.97); box-shadow: inset 0 2px 4px rgba(0,0,0,0.25); }
LWC — Configuration
<?xml version="1.0" encoding="UTF-8"?>
<LightningComponentBundle xmlns="http://soap.sforce.com/2006/04/metadata">
  <apiVersion>59.0</apiVersion>
  <isExposed>true</isExposed>
  <targets><target>lightning__AppPage</target><target>lightning__RecordPage</target><target>lightning__HomePage</target></targets>
</LightningComponentBundle>

Where Claymorphism Button fits

  • Education
  • Kids Apps
  • AI Assistants
  • Landing Pages

Interaction states & animations

  • Hover
  • Bounce
  • Squish
  • Elastic

Topics

  • #clay
  • #puffy
  • #soft
  • #playful
  • #friendly
  • #3d

Accessibility notes

Maintain WCAG 2.2 AA contrast. Focus ring should stand out against the soft surface.

Browser support

  • All modern browsers