On the one hand, it can be used as an ordinary verb and has the same forms as an ordinary verb. The third person singular ends with an s, and questions and negatives are formed with do. As an ordinary verb, need is normally followed by an infinitive with to:
A: He needs to see a doctor. Do you need to see one too?
B: No, I don't need to see a doctor. But I need a good rest.
In this sense, when we are talking about necessity, we generally prefer need to / do not need to.
从这个角度讲，当我们谈论“必须”时，我们一般倾向于使用need to / do not need to(也就是将need作为实义动词用)。
In the other format, need behaves as a modal verb, like can, could, must, should, etc. It has the same forms as modal auxiliary verbs: the third person singular has no s, questions and negatives are made without do. In this format, need is followed by an infinitive without to:
另一方面，need还可用作情态动词，就像can, could, must, should等词那样。此时它的用法同其他情态助动词一样：第三人称单数作主语时不加s，疑问句和否定句不用do来构成。做情态动词时，need一般接不带to的不定式。例句：
A: Need I lock the door when I leave?
B: No, you needn't. Sarah will be home soon.
In this sense, we are talking more about obligation and giving permission to someone not to do something. Note also that as a modal verb it is most commonly used in negative sentences and sometimes in questions.
Compare the following alternatives to needn't and don't need to in the examples below:
试比较下面对于例句中 needn't 和 don't need to 的替换用法：
1. You needn't come if you don't want to.
Alternative: Don't feel obliged to come if you don't want to.
2. You don't need to be a genius to see that it is wrong.
Alternative: You don't have to be a genius to see that it is wrong.