Relation extraction task aims at detecting the semantic relation between a pair of entities in a given target sentence. However, previous methods lack the description of the relation definition, thus needing to model the implication of relations during training. To tackle this issue, we propose a natural language inference method for relation extraction. Given a premise and a hypothesis, the natural language inference task refers to predicting whether the facts in the premise necessarily imply the facts in the hypothesis. Specifically, for each relation type, we construct a relation description. These relation descriptions are the definition of relation, containing prior knowledge that helps model understand the meaning of relation. The given target sentence is viewed as the premise, and these descriptions are viewed as the hypotheses. Then model infers whether these hypotheses can be concluded from the premise. Based on the inference results, our model selects the relation corresponding to the most confident hypothesis as the prediction. Substantial experiments on SemEval2010 Task8 dataset demonstrate that the proposed method achieves state-of-the-art performance.