At things like StartUp Weekend, prizes help teams move their project forward – time with a lawyer, some startup cash, access to expensive dev tools, etc. At GWOB events, we usually give prizes which are coding books, comics, and hardware kits; all to get people thinking in new spaces. Another set of prizes might be qualifying to work towards a bounty of DELIVERING a working prototype (or some other milestone) by X months after the hackathon. Or just use prize money towards that, and use the hackathon as a time to onboard people to the ideas. (I think I would even wait to tell people about the bounty until the hackathon itself).
Prizes sure can be great for attracting attendees. For people with many options in front of them for how to spend their time, prizes can incentivize attendance. This can also mean attendees might view the prize as compensation for their time – a strange mental space to be in, especially if not a winner. Prizes can also incentivize people to focus and to push themselves out of friendly (or unfriendly) competitiveness.