"I enjoy to swim" is wrong. "I want swimming" is wrong. There is no rule that predicts which verbs take which — but the lists are short enough to learn.

Verbs followed by -ing

enjoy, avoid, finish, mind, suggest, consider, practise, imagine, keep, miss, admit

  • "I enjoy reading."
  • "She avoided answering the question."
  • "Do you mind waiting?"

Verbs followed by to + verb

want, need, decide, hope, plan, promise, agree, refuse, learn, offer, manage

  • "I want to leave."
  • "They decided to postpone it."
  • "He managed to finish on time."

Verbs that take both, same meaning

begin, start, continue, like, love, hate, prefer

  • "It started raining." = "It started to rain."

Verbs that take both, different meaning

This is the part worth real attention.

  • "I stopped smoking." (quit the habit) vs "I stopped to smoke." (paused in order to smoke)
  • "I remember locking the door." (I have the memory) vs "Remember to lock the door." (do not forget)
  • "I tried calling him." (I called, as an experiment) vs "I tried to call him." (I attempted, possibly failing)

After prepositions, always -ing

  • "Thank you for helping."
  • "I'm interested in learning more."
  • "She's good at explaining things."

Watch out for "look forward to" — the to here is a preposition, so it takes -ing: "I look forward to hearing from you."

That last one appears in almost every professional email, and "look forward to hear from you" is one of the most common written errors.