Objectives:To develop an IoT-based smart device to retrieve soil and water parameters by collecting and storing sensor-based data and to make crop recommendations. The primary goal of this work is to create a link between farmers and their farms. Methods: This work produces a smart device to predict suitable crop based on several parameters using a technical approach that makes use of the Internet of Things, Machine learning algorithms, and Sensor Networks. The Gaussian Naive Bayes algorithm is used in the Prediction module to predict suitable crop types. Several components are used to make an IoT system like Raspberry Pi, DHT11 sensor, soil moisture sensor, pH sensor, LDR sensor, Ultrasonic sensor, NPK sensor, and other components to collect data related to soil properties and weather conditions. Soil samples were collected from different fields and tested by switching the IoT kit and the message will be passed to the field owner. Dataset is used from the Kaggle database to train the model for crop prediction. Seven parameters have been taken in the trained dataset such as pH, N, P, K, temperature, humidity, and rainfall. All these values were collected through soil properties sensors and weather condition sensors. Existing traditional methods like soil testing laboratories involve lengthy and costly procedures for soil testing and crop prediction. The proposed system will produce results faster at a lesser cost while making digital data available on the cloud server. Findings: The proposed system performs efficiently when compared to the previous report with 99.3% accuracy over 97.18%. The existing approach for lab-based soil testing takes approximately 5 -8 days; whereas the proposed system using an IoT kit can perform n number of soil tests on a single device and the results can be viewed instantly. Novelty: Most of the existing systems like smart agriculture system and smart irrigation system use Arduino Uno for soil test which doesn't support high-end sensors and works only with desktop computer traditional programs. The existing system for nutrient identification uses a soil Ec sensor and color sensor to find N, P, and K values which include multi-steps and are time-consuming. The proposed system uses Raspberry Pi for soil tests which are more compatible with implementing the latest machine-level algorithms. In this system, the NPK sensor is used instead of soil Ec sensor and color sensor which will give the N, P, and K values directly.