How do I get rid of ill will? People who have done wrong to me remain in my memory and continuously stay in my mind. I have feelings of ill will and hatered towards them...to revenge...how do I get out of the feelings of ill will...
Vitakkasanthana Sutta (MN 20) 

Please keep in mind that one's effort should be of ardency and urgency. You have to act like a hero and free yourself from these. You need to have wisdom about defilements, otherwise you will find excuses and dwell in them even further.

1) "Divert your attention to something more skillful". Now, this doesn't necessarily mean to change one's ill-will to compassion via metta meditation, since the ill-will has too much energy and your thoughts are therefore distorted and won't let good thoughts in so easily. Therefore attend to something skillful but nothing unrealistically positive, for your current state of mind ( ill-will in that case) is too strong. You can try to give self compassion to yourself, i.e.that you are quite angry and that you are not feeling well (treat yourself like a little child). After that, once you feel better you see that other person might also get angry so that you have a sense of not being alone with that problem and you then send metta to these people.

2) Repeatedly scrutinize the benefits of letting go of negative mind states and the benefits of positive ones (both for you and how it contributes to other people as well)

3) Step 3 in the sutta mentions: "Paying no mind to thoughts". Since not thinking of a thought or even aversion to it doesn't really eliminate it, my adive is to always accept the presence of the thought and then distract myself and do something else (or just curiously observe it and see its impermanence). At best, I would always employ a cognitive technique like Step 2 and a behavioral one (like standing up and doing something else while keeping the drawbacks and benefits in mind)


"Relaxation of thoughts". Basically "cooling off", for example via breathing and internally saying: "I'm breathing in sensitively.. breathing out sensitively". "Anger only makes matters worse.. both for me and for others" (connected to step 2)
Clenching one teeths. Now I don't  know how this one is to be understood, but surpressing thoughts in the sense of "don't think of xyz" doesn't work. I recommend contemplating the Buddha's strengths like energy and determination etc. and follow the steps above.



  "There is the case where evil, unskillful thoughts — imbued with desire, aversion, or delusion — arise in a monk while he is referring to and attending to a particular theme. He should attend to another theme, apart from that one, connected with what is skillful. When he is attending to this other theme, apart from that one, connected with what is skillful, then those evil, unskillful thoughts — imbued with desire, aversion, or delusion — are abandoned and subside. With their abandoning, he steadies his mind right within, settles it, unifies it, and concentrates it. Just as a skilled carpenter or his apprentice would use a small peg to knock out, drive out, and pull out a large one; in the same way, if evil, unskillful thoughts — imbued with desire, aversion, or delusion — arise in a monk while he is referring to and attending to a particular theme, he should attend to another theme, apart from that one, connected with what is skillful. When he is attending to this other theme, apart from that one, connected with what is skillful, then those evil, unskillful thoughts — imbued with desire, aversion, or delusion — are abandoned and subside. With their abandoning, he steadies his mind right within, settles it, unifies it, and concentrates it.
  
  If evil, unskillful thoughts — imbued with desire, aversion, or delusion — still arise in the monk while he is attending to this other theme, connected with what is skillful, he should scrutinize the drawbacks of those thoughts: 'Truly, these thoughts of mine are unskillful, these thoughts of mine are blameworthy, these thoughts of mine result in stress.' As he is scrutinizing the drawbacks of those thoughts, those evil, unskillful thoughts — imbued with desire, aversion, or delusion — are abandoned and subside. With their abandoning, he steadies his mind right within, settles it, unifies it, and concentrates it. Just as a young woman — or man — fond of adornment, would be horrified, humiliated, and disgusted if the carcass of a snake or a dog or a human being were hung from her neck; in the same way, if evil, unskillful thoughts — imbued with desire, aversion, or delusion — still arise in the monk while he is attending to this other theme, connected with what is skillful, he should scrutinize the drawbacks of those thoughts: 'Truly, these thoughts of mine are unskillful, these thoughts of mine are blameworthy, these thoughts of mine result in stress.' As he is scrutinizing the drawbacks of those thoughts, those evil, unskillful thoughts — imbued with desire, aversion, or delusion — are abandoned and subside. With their abandoning, he steadies his mind right within, settles it, unifies it, and concentrates it.
  
  "If evil, unskillful thoughts — imbued with desire, aversion or delusion — still arise in the monk while he is scrutinizing the drawbacks of those thoughts, he should pay no mind and pay no attention to those thoughts. As he is paying no mind and paying no attention to them, those evil, unskillful thoughts are abandoned and subside. With their abandoning, he steadies his mind right within, settles it, unifies it, and concentrates it. Just as a man with good eyes, not wanting to see forms that had come into range, would close his eyes or look away; in the same way, if evil, unskillful thoughts — imbued with desire, aversion or delusion — still arise in the monk while he is scrutinizing the drawbacks of those thoughts, he should pay no mind and pay no attention to those thoughts. As he is paying no mind and paying no attention to them, those evil, unskillful thoughts are abandoned and subside. With their abandoning, he steadies his mind right within, settles it, unifies it, and concentrates it.
  
  "If evil, unskillful thoughts — imbued with desire, aversion or delusion — still arise in the monk while he is paying no mind and paying no attention to those thoughts, he should attend to the relaxing of thought-fabrication with regard to those thoughts. As he is attending to the relaxing of thought-fabrication with regard to those thoughts, those evil, unskillful thoughts are abandoned and subside. With their abandoning, he steadies his mind right within, settles it, unifies it, and concentrates it. Just as the thought would occur to a man walking quickly, 'Why am I walking quickly? Why don't I walk slowly?' So he walks slowly. The thought occurs to him, 'Why am I walking slowly? Why don't I stand?' So he stands. The thought occurs to him, 'Why am I standing? Why don't I sit down?' So he sits down. The thought occurs to him, 'Why am I sitting? Why don't I lie down?' So he lies down. In this way, giving up the grosser posture, he takes up the more refined one. In the same way, if evil, unskillful thoughts — imbued with desire, aversion or delusion — still arise in the monk while he is paying no mind and paying no attention to those thoughts, he should attend to the relaxing of thought-fabrication with regard to those thoughts. As he is attending to the relaxing of thought-fabrication with regard to those thoughts, those evil, unskillful thoughts are abandoned and subside. With their abandoning, he steadies his mind right within, settles it, unifies it, and concentrates it.
  
  "If evil, unskillful thoughts — imbued with desire, aversion or delusion — still arise in the monk while he is attending to the relaxing of thought-fabrication with regard to those thoughts, then — with his teeth clenched and his tongue pressed against the roof of his mouth — he should beat down, constrain, and crush his mind with his awareness. As — with his teeth clenched and his tongue pressed against the roof of his mouth — he is beating down, constraining, and crushing his mind with his awareness, those evil, unskillful thoughts are abandoned and subside. With their abandoning, he steadies his mind right within, settles it, unifies it, and concentrates it. Just as a strong man, seizing a weaker man by the head or the throat or the shoulders, would beat him down, constrain, and crush him; in the same way, if evil, unskillful thoughts — imbued with desire, aversion or delusion — still arise in the monk while he is attending to the relaxing of thought-fabrication with regard to those thoughts, then — with his teeth clenched and his tongue pressed against the roof of his mouth — he should beat down, constrain, and crush his mind with his awareness. As — with his teeth clenched and his tongue pressed against the roof of his mouth — he is beating down, constraining, and crushing his mind with his awareness, those evil, unskillful thoughts are abandoned and subside. With their abandoning, he steadies his mind right within, settles it, unifies it, and concentrates it.


Regarding the fifth point in the Sutta: Sometimes there is also the word "surpressing" mentioned (or at least Ajahn Sona in one of his videos said "surpression"). However above, the Buddha says "constraining and beating down with one's awareness."
 Is someone familiar with this sutta? Does it really mean awareness? I wouldn't personally interpret that as "don't think of xyz" (since it doesn't work), but rather about forcing one's mind to concentrate on an object and thereby "crushing" one's thoughts. Now I don't know how the fifth method would differ then from the fourth. Any ideas? I think the difference would be the emphasize, that is: the urgency and ardency to rid oneself from these defilements.