Different verbs are followed by different forms: some take INFINITIVE (to + verb), some take GERUND (verb + -ing), some take BOTH. There's no rule - you must MEMORIZE the patterns!
Quick tip: Want/decide/plan/hope/promise = TO + verb. Enjoy/finish/keep/mind/avoid = verb + -ING. Like/love/hate/start = BOTH. Memorize the lists!
VERBS + infinitive (TO + verb)
Common verbs followed by TO + verb: want, need, would like, decide, plan, hope, promise, agree, refuse, offer, learn, manage, afford, choose, expect, fail.
I want to go home. (NOT: want going)
She decided to quit her job. (NOT: decided quitting)
We plan to travel next year. (NOT: plan traveling)
He promised to help me. (NOT: promised helping)
VERBS + gerund (verb + -ING)
Common verbs followed by -ING: enjoy, finish, keep, mind, avoid, suggest, practice, consider, imagine, miss, deny, admit, risk, fancy, can't stand, can't help.
I enjoy reading books. (NOT: enjoy to read)
She finished doing her homework. (NOT: finished to do)
They keep making mistakes. (NOT: keep to make)
Do you mind waiting? (NOT: mind to wait)
VERBS + BOTH (meaning is the SAME)
Some verbs can use BOTH infinitive and gerund with NO change in meaning: like, love, hate, prefer, start, begin, continue.
I like to read. = I like reading. (same meaning)
She loves to dance. = She loves dancing. (same meaning)
He hates to wait. = He hates waiting. (same meaning)
It started to rain. = It started raining. (same meaning)
Common mistakes
Not "I enjoy to read books." — say "I enjoy reading books.". ENJOY always takes -ING form (gerund), never infinitive..
Not "She wants going home." — say "She wants to go home.". WANT always takes infinitive (TO + verb), never gerund..
Not "He's good at to cook." — say "He's good at cooking.". After prepositions (at/in/of/for), use GERUND (-ING), not infinitive..