<!-- mobian-agent-page publisher="dailydev" canonical="https://daily.dev/posts/hyper-realistic-sand-with-webgl2-kqo2wxur6" -->

---
title: Hyper-Realistic Sand with WebGL2 | daily.dev
description: This browser-based project simulates sand using WebGL2 and JavaScript. You can drag to draw grains, tilt your phone to slide them around, and shake to scatter...
canonical: https://daily.dev/posts/hyper-realistic-sand-with-webgl2-kqo2wxur6
twitter:card: summary_large_image
twitter:site: @dailydotdev
og:type: website
og:site_name: daily.dev
og:title: Hyper-Realistic Sand with WebGL2 | daily.dev
og:description: This browser-based project simulates sand using WebGL2 and JavaScript. You can drag to draw grains, tilt your phone to slide them around, and shake to scatter...
og:url: https://daily.dev/posts/hyper-realistic-sand-with-webgl2-kqo2wxur6
og:image: https://api.daily.dev/og/posts/KqO2WXur6.png
og:image:alt: Hyper-Realistic Sand with WebGL2
og:image:width: 1200
og:image:height: 630
og:locale: en
---

> ## Documentation Index
> Fetch the complete documentation index at: https://daily.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# Hyper-Realistic Sand with WebGL2

**[Hacker News](https://daily.dev/sources/hn)** · 1 min read · 0 upvotes · 0 comments

## Summary

This browser-based project simulates sand using WebGL2 and JavaScript. You can drag to draw grains, tilt your phone to slide them around, and shake to scatter the sand. Play right in your browser. The page notes that WebGL2 is not available on this device.

## Full article

daily.dev links to this article rather than hosting it. Read it at the original source: <https://av.github.io/safe-sand>

## Community take

How the wider developer community reacted, aggregated from 1 discussion and 50 comments across hackernews (as of 2026-11-11).

**TL;DR:** People are impressed by the visual feel and playfulness of the sand simulation, but many ran into bugs and performance issues on mobile devices and quibble with physics details like stuck grains, abrupt stopping, and fast-moving stones.

**Sentiment:** 55% positive · 35% mixed · 10% skeptical

**The case for**

- Many found it genuinely fun and immersive to play with, especially the tilt/shake interactions on mobile.
- The water pooling around stones and realistic pile collapse were called out as impressively lifelike details.
- Different sand types (desert vs. beach) were appreciated for having distinct visual characteristics.

**The pushback**

- Mobile behavior is inconsistent: some saw broken animations, no response to shaking, or orientation resets.
- Performance is poor on several phones (choppy, low fps) and one commenter said it 'runs like crap' on an iPhone 14.
- Physics critiques include sand appearing stuck/not moving, lack of momentum, stones moving too fast without friction, and an odd pressure/bounce-back effect.
- The sound effect was called bad or jarring with a harsh cutoff, with some suggesting it be removed.

**By community**

- hackernews (mixed): Reactions split between delight at the look and feel of the simulation and frustration with mobile bugs, performance, and physics nitpicks.

**Hottest debate:** Whether the simulation actually feels 'realistic' is contested, with some praising the physical feel and others pointing out stuck grains, odd pressure effects, and missing momentum.

**Open questions**

- Why does mobile behavior vary so much across devices and browsers (some see broken animations, others nothing happens)?
- Is there a meaningful technical reason performance differs so much between phone generations?

**Highlights**

> I wouldn’t call it realistic, sand gets stuck in the air, stones don’t rotate, and there’s quite an uncanny valley effect based on angles. Still a cool demo of what is possible, even though I get 10fps or something on a iPhone 15 Pro
> — [techpression on hackernews · 2 comments](https://news.ycombinator.com/item?id=50454971)

> oh wow, the stones even have some water around them. This looks and feels real. And if you manage to collect a lot in one place, the sand from the pile does fall like real sand. This is amazing. The sound is not good though.
> — [smusamashah on hackernews · 2 comments](https://news.ycombinator.com/item?id=50455710)

> I think it's lacking momentum, the sand stops way too abruptly, and the audio also has too harsh cutoff. It also falls too fast. Otherwise really amazing!
> — [emilfihlman on hackernews](https://news.ycombinator.com/item?id=50456098)

> This is annoying to clean up exactly like real sand.
> — [nout on hackernews · 1 comments](https://news.ycombinator.com/item?id=50455242)

> Something seems wrong with the stones. They seem to move way to fast. They need more friction.
> — [nkmnz on hackernews](https://news.ycombinator.com/item?id=50456963)

**Source threads**

- [hackernews](https://news.ycombinator.com/item?id=50453288) · 178 points · 50 comments

## Similar posts on daily.dev

- [Explore This Tactile UI Powered By Real-Time WebGL Shader](https://daily.dev/posts/explore-this-tactile-ui-powered-by-real-time-webgl-shader-unjsszd7a) · 80 LEVEL · 1 upvotes · 0 comments
- [Simulating Life in the Browser: Creating a Living Particle System for the UntilLabs Website](https://daily.dev/posts/simulating-life-in-the-browser-creating-a-living-particle-system-for-the-untillabs-website-nmsokbiv8) · Codrops · 2 upvotes · 0 comments
- [Immersive Gel, Sand & Water Simulations On Apple Vision Pro](https://daily.dev/posts/immersive-gel-sand-water-simulations-on-apple-vision-pro-mth78aeyp) · 80 LEVEL · 0 upvotes · 0 comments
- [snow simulation toy](https://daily.dev/posts/snow-simulation-toy-zovadkjzs) · Hacker News · 0 upvotes · 1 comments

---

Tags: [#javascript](https://daily.dev/tags/javascript), [#physics](https://daily.dev/tags/physics), [#webgl](https://daily.dev/tags/webgl)

[View this post on daily.dev](https://daily.dev/posts/hyper-realistic-sand-with-webgl2-kqo2wxur6)

```json
{"@context":"https://schema.org","@graph":[{"@type":"Organization","@id":"https://daily.dev/#organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180},"sameAs":["https://twitter.com/dailydotdev","https://github.com/dailydotdev","https://www.linkedin.com/company/daily-dev-ltd"]},{"@type":"WebSite","@id":"https://daily.dev/#website","url":"https://daily.dev","name":"daily.dev","publisher":{"@id":"https://daily.dev/#organization"},"potentialAction":{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https://daily.dev/search?q={search_term_string}"},"query-input":"required name=search_term_string"}}]}
{"@context":"https://schema.org","@type":"TechArticle","headline":"Hyper-Realistic Sand with WebGL2","url":"https://daily.dev/posts/hyper-realistic-sand-with-webgl2-kqo2wxur6","mainEntityOfPage":{"@type":"WebPage","@id":"https://daily.dev/posts/hyper-realistic-sand-with-webgl2-kqo2wxur6"},"datePublished":"2026-11-11T16:29:39.285Z","dateModified":"2026-11-11T18:48:58.891Z","description":"This browser-based project simulates sand using WebGL2 and JavaScript. You can drag to draw grains, tilt your phone to slide them around, and shake to scatter...","image":"https://media.daily.dev/image/upload/s--foaA6JGU--/f_auto/v1722860399/public/Placeholder%2004","thumbnailUrl":"https://media.daily.dev/image/upload/s--foaA6JGU--/f_auto/v1722860399/public/Placeholder%2004","isAccessibleForFree":true,"articleSection":"Hacker News","inLanguage":"en","publisher":{"@type":"Organization","name":"daily.dev","url":"https://daily.dev","logo":{"@type":"ImageObject","url":"https://daily.dev/apple-touch-icon.png","width":180,"height":180}},"author":{"@type":"Organization","name":"Hacker News","logo":"https://media.daily.dev/image/upload/t_logo,f_auto/v1/logos/hn","url":"https://daily.dev/sources/hn"},"commentCount":0,"discussionUrl":"https://daily.dev/posts/hyper-realistic-sand-with-webgl2-kqo2wxur6","interactionStatistic":[{"@type":"InteractionCounter","interactionType":{"@type":"LikeAction"},"userInteractionCount":0},{"@type":"InteractionCounter","interactionType":{"@type":"CommentAction"},"userInteractionCount":0}],"keywords":"javascript,physics,webgl","timeRequired":"PT1M"}
{"@context":"https://schema.org","@type":"BreadcrumbList","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https://daily.dev"},{"@type":"ListItem","position":2,"name":"Hacker News","item":"https://daily.dev/sources/hn"},{"@type":"ListItem","position":3,"name":"Hyper-Realistic Sand with WebGL2"}]}
```

