
517 P.2d 182 (1973)
James L. MILLER, Appellant,
v.
The STATE of Nevada, Respondent.
No. 7067.
Supreme Court of Nevada.
December 20, 1973.
Raymond E. Sutton, Las Vegas, for appellant.
Robert List, Atty. Gen., Carson City, Roy A. Woofter, Dist. Atty., and Charles L. Garner, Chief Deputy, Dist. Atty., Las Vegas, for respondent.

OPINION
THOMPSON, Chief Justice:
This appeal is from a final judgment of the district court denying the motion of James L. Miller to withdraw his plea of guilty to a charge of the sale of heroin. His motion to withdraw such plea was made after the imposition of sentence to correct a manifest injustice.[1] It is his contention that he was under the influence of heroin when he pleaded guilty. After an evidentiary hearing the district court found that his plea was entered voluntarily, knowingly and intelligently even though he was to some degree under the influence of heroin. He was represented by counsel when he pleaded guilty.
A conviction of an accused while legally incompetent violates due process and must be set aside. Krause v. Fogliani, 82 Nev. 459, 421 P.2d 949 (1966). It does not inevitably follow, however, that a guilty plea by one under the influence of narcotics is per se invalid. The influence of narcotics must be such as to affect his competency to stand trial or his capacity to understand the nature and consequences of his plea. Grennett v. United States, 131 U.S.App.D.C. 202, 403 F.2d 928 (1968); Holmes v. United States, 323 F.2d 430 (7th Cir.1963); United States ex rel. Fitzgerald v. LaVallee, 461 F.2d 601 (2nd Cir.1972). It is his obligation to persuade the trial court by a preponderance of the evidence *183 that he was so influenced. Grennett v. United States, supra. The record in this case does not allow us to rule that the court below abused its discretion in ruling that Miller failed to sustain his burden of proof. Cf. State v. District Court, 85 Nev. 381, 455 P.2d 923 (1969). Although it is undisputed that he was, to some degree, under the influence of heroin when he pleaded guilty, it also is apparent that the court could find that he fully understood the nature and consequences of his plea.
Affirmed.
MOWBRAY, GUNDERSON, BATJER and ZENOFF, JJ., concur.
NOTES
[1]  NRS 176.165. "... a motion to withdraw a plea of guilty or of nolo contendere may be made only before sentence is imposed or imposition of sentence is suspended; but to correct manifest injustice the court after sentence may set aside the judgment of conviction and permit the defendant to withdraw his plea."
