I hit my thumb today with a hammer and now it's black under the nail from the bottom up to almost the middle of the nail half moon shaped. Hurts also?

Treatment advice? You are reporting so called sub-ungual (under nail) hematoma. Releasing blood could be considered if very painful. I release blood using red hot tip of a bent paper clip. Bend one end of clip 90 degrees, heat it till red hot with flame, e.g. From a lighter.Then push tip of paper clip thru center of hematoma in nail. Cip will burn tiny hole, blood will be released ; blood immediately cools clip tip.
Nail Injury. I do not see a question here. So, the facts are: you injured your thumb. There is a bruise under the nail. This sounds like a normal response to an injury.