Wireless sensors and actuators have limited resources and low bandwidth wireless communication ability while they are low-cost and energy-efficient. These devices can form ad hoc wireless networks and can be connected to the internet through the gateways. The resource constrained wireless devices cannot afford the general internet protocols so that they cannot be directly accessed through the internet. In this paper, we propose a cloud-enabled web services solution to address this issue. The functions of device are encapsulated into web services and submitted to the cloud; the client operates the device by invoking the web services; and the gateway converts messages between the device and the cloud. Using the standard web services architecture instead of customised SOA solutions and deploying services to the cloud instead of wireless nodes or gateways reduce the resource demand of nodes and gateways, simplify the wireless network design, and provide a uniform interface for using and managing devices.