divskeletonbeginner
Loading Skeleton
A skeleton placeholder with animated shimmer effect for content loading states.
Preview
<div class="max-w-sm p-4 space-y-4">
<div class="flex items-center gap-3">
<div class="w-10 h-10 bg-gray-200 rounded-full animate-pulse"></div>
<div class="flex-1 space-y-2">
<div class="h-3 bg-gray-200 rounded-full animate-pulse w-24"></div>
<div class="h-2 bg-gray-200 rounded-full animate-pulse w-16"></div>
</div>
</div>
<div class="space-y-2">
<div class="h-3 bg-gray-200 rounded-full animate-pulse"></div>
<div class="h-3 bg-gray-200 rounded-full animate-pulse w-5/6"></div>
<div class="h-3 bg-gray-200 rounded-full animate-pulse w-4/6"></div>
</div>
<div class="h-40 bg-gray-200 rounded-lg animate-pulse"></div>
</div>Color Breakdown
Skeleton Color
bg-gray-200
#e5e7eb
Dark Mode Variant
Add these Tailwind classes for a dark mode adaptation of this recipe.
dark:bg-gray-700Use Cases
Content loading statesFeed placeholdersCard loading previews
Browser Support
All modern browsers. CSS animations supported in all evergreen browsers.
Related Recipes
Build Your Own Color Recipe
Use our Tailwind CSS tools to experiment with colors, gradients, and component styles.
Explore ToolsFrequently Asked Questions
Should I use skeleton or spinner for loading?▼
Skeletons are better for content areas where the layout is known. Spinners are better for actions where the content shape is unknown.