The following snippet will let you redirect users to random WordPress posts.

Snippet Source/Credit: Smashing Magazine