Hi,
This is a recurrent question, so I will point you to two links that might help you: here and here.
Please feel free to follow up if you have specific questions about their approach or if something is not working in your particular use case.