Good question. The technical answer is that "fun" is the noun form: We had a lot of fun at Alberto's party.
"Funny" is an adjective, but be careful. It's not automatically the adjective version of "fun": As the British say, there's funny ha-ha and funny peculiar.
"Funny ha-ha" is the definition that most people know - something that's amusing and makes you laugh: I have a really funny joke to tell you!
BUT - and this is a big but - in spoken English, it means "strange, not quite right" or "suspicious:"
- Something funny happened to me the other day....a pumpkin fell on my head.
- It's funny how things never work out how you expect them to.
- He gave me a funny look when I asked him about his mother.
- The accountant wondered if his client was doing something funny with his money.
In these cases, "funny" has nothing to do with humour. It's closer to the idea of deception or tricks.