Generally, you can qualify for widow(er)'s benefits as long as you satisfy the following conditions: 1) you are at least 60 years old, 2) you were married for at least nine months just before the worker died, and 3) your deceased spouse would have been eligible for Social Security retirement benefits. (Please note: there are many exceptions to the nine-month rule; to see them, see "Marriage requirement to receive survivors benefits".)
If you have your own Social Security retirement benefits, you can choose to take one or the other. In some circumstances, you may want to start with one benefit and, at a later date, switch to the other one. For more detail, see the discussion in this SSA material. Widows (and even some widowers) may also find the SSA publication ("What Every Woman Should Know" informative. Another informative SSA publication is Survivor's Benefits.