Section 466(1) in The Code of Criminal Procedure, 1989 (1933 A. D.)
(1)Whenever an accused person is found to be of unsound mind and incapable of making his defence, the Magistrate or Court, as the case may be, whether the case is one in which bail may be taken or not, may release him on sufficient security being given that he shall be properly taken care of and shall be prevented from doing injury to himself or to any other person, and for his appearance when required before the Magistrate or Court or such officer as the Magistrate or Court appoints in this behalf.