An electronic device comprising: a box-shaped housing; a circuit substrate housed in the housing; a connector that is mounted to the circuit substrate and that has a portion exposed to outside of the housing; and a seal obtained by a sealant having fluidity being hardened, wherein the housing includes a lower case and an upper case that covers the lower case, the connector is disposed between the upper case and the lower case, the lower case has, in a surface on the upper case side of the lower case, a case groove that extends along a peripheral edge portion of the surface, the upper case has, on a surface on the lower case side of the upper case, a case projection that extends along a peripheral edge portion of the surface, the connector has a connector groove in a surface on the upper case side, and has a connector projection on a surface on the lower case side, the connector projection is fitted into the case groove and the case projection is fitted into the connector groove at a position at which the connector is disposed between the upper case and the lower case, the case projection is fitted into the case groove at a position at which the connector is not disposed between the upper case and the lower case, the seal is filled in a gap between the case groove and each of the case projection and the connector projection, and in a gap between the connector groove and the case projection, and projections disposed on a side wall of the case groove or the connector groove, the projections serving as an obstructor for inhibiting flow of the sealant, wherein, in the case groove or the connector groove, a plurality of the projections is aligned in a direction in which the groove (18, 32) extends, characterized in that a proportion of a width (Wp) of the projections to a distance (Dg) between the projections is not less than 5 % and not greater than 25 %. a box-shaped housing; a circuit substrate housed in the housing; a connector that is mounted to the circuit substrate and that has a portion exposed to outside of the housing; and a seal obtained by a sealant having fluidity being hardened, wherein the housing includes a lower case and an upper case that covers the lower case, the connector is disposed between the upper case and the lower case, the lower case has, in a surface on the upper case side of the lower case, a case groove that extends along a peripheral edge portion of the surface, the upper case has, on a surface on the lower case side of the upper case, a case projection that extends along a peripheral edge portion of the surface, the connector has a connector groove in a surface on the upper case side, and has a connector projection on a surface on the lower case side, the connector projection is fitted into the case groove and the case projection is fitted into the connector groove at a position at which the connector is disposed between the upper case and the lower case, the case projection is fitted into the case groove at a position at which the connector is not disposed between the upper case and the lower case, the seal is filled in a gap between the case groove and each of the case projection and the connector projection, and in a gap between the connector groove and the case projection, and projections disposed on a side wall of the case groove or the connector groove, the projections serving as an obstructor for inhibiting flow of the sealant, wherein, in the case groove or the connector groove, a plurality of the projections is aligned in a direction in which the groove (18, 32) extends, characterized in that a proportion of a width (Wp) of the projections to a distance (Dg) between the projections is not less than 5 % and not greater than 25 %.