First of all, you should know whether there is a permit or license required to catch or trap hawks in your state. It is unlawful in many states and you have to get the permission of concerned authorities before trapping or catching hawks.
If you are living in USA and want to catch or trap hawks then you have to get permit from the U.S Fish and Wildlife Services which is the relevant authority.
After getting the permit or license if required, you need to give close observation to the timings in which usually hawks come to your farm. It will help you in employing the trapping or catching methods on the right time.
You should also try to protect your small animals or birds from hawk attacks by keeping them in a covered area which will help in reducing the frequency of hawk attacks.
At first try your best to make the hawk scared by making a good and timely use of scarecrow that produces loud noises and keeps the crows and hawks away from your farm. However, you still need to apply trapping methods for hawks as you cannot remain present at farm all the time.
You need to buy a Swedish goshawk trap for catching a hawk. You can also use bal-chatri trap which is equally effective and is used by a huge number of people all over the world for catching hawks.
Then purchase live mice for attracting hawk towards the bal-chatri or Swedish goshawk trap. Usually hawks attack on mice with great eager and get trapped in the already set trap.
Make sure you have put the trap in an area where you observe hawks come frequently. Make sure you have covered the trap with a blanket or other cloth.
Keep checking the trap after a few hours and if you find any hawk trapped then you should transport it to a nearby wildlife agency.