
R3f Physics
React Three Fiber physics with Rapier: rigid bodies, colliders, forces, sensors, joints, and character controllers.
- skills.sh installs
- 2.1K
- GitHub stars
- 138
- last updated
- Aug 21, 2026
What it does
- Covers dynamic, fixed, and kinematic RigidBody setup, colliders, impulses and persistent forces, and fixed-timestep simulation behavior
- Includes sensor intersection events, collision groups, joints using local anchors, and a step-aligned kinematic platform reference
- Enforces separation of rendering and simulation ownership, so simulated meshes are not animated directly in
useFrame - Designed for collision-driven movement and simulation in projects on Fiber 9, React 19, and Rapier 2
Install
$ npx -y skills add enzed/r3f-skills --skill r3f-physics -yInstalls into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.
Files
React Three Fiber physics
Check installed Fiber, React, and Rapier versions. Rapier 2 targets Fiber 9 / React 19; older projects need their compatible package line. Keep rendering and simulation ownership separate.
Falling and clickable body
Mount beneath Canvas with lighting. Physics loads WASM asynchronously; include Suspense. Cuboid collider arguments are half-extents, unlike BoxGeometry's full dimensions.
import { Suspense, useRef } from 'react'
import { CuboidCollider, Physics, RigidBody, type RapierRigidBody } from '@react-three/rapier'
function FallingBox() {
const body = useRef<RapierRigidBody>(null)
return (
<RigidBody ref={body} position={[0, 2, 0]} colliders="cuboid" restitution={0.2}>
<mesh name="physics-box" onClick={() => body.current?.applyImpulse({ x: 0, y: 3, z: 0 }, true)}>
<boxGeometry />
<meshStandardMaterial color="coral" />
</mesh>
</RigidBody>
)
}
Details
- Repository
- github.com/enzed/r3f-skills
- Categories
- 3D, CAD & Modeling, Frontend & UI Code, Game Development
- First seen
- May 16, 2026
More from enzed/r3f-skills
All 11Similar to R3f Physics
More 3D, CAD & Modeling
r3f-interactionenzed/r3f-skills3.5K installsReact Three Fiber input handling covering pointer picking, drag ownership, camera controls, and keyboard movement.
r3f-fundamentalsenzed/r3f-skills2.4K installsReact Three Fiber scene setup with Canvas, typed JSX, hooks, render-loop control, and resource ownership rules.
godot-physics-3dthedivergentai/game-dev-agentic-skills255 installsExpert 3D physics patterns for Godot covering bodies, ragdolls, joints, CCD, and collision layers.
react-native-r3fmindrally/skills695 installsExpert guidance for React Three Fiber scenes using React, Vite, Tailwind CSS, and Next UI conventions.
web3d-integration-patternsfreshtechbro/claudedesignskills3.6K installsMeta-skill that combines Three.js, GSAP ScrollTrigger, React Three Fiber, Motion, and React Spring into one 3D architecture.
ue-physics-collisionquodsoler/unreal-engine-skills1.4K installsCollision channels, traces, overlaps, and physics simulation for Unreal Engine 5.8 C++ code.