Gilbert proposed an algorithm for bounding the distance between a given point and a convex set. We apply the Gilbert's algorithm to get an upper bound on the Hilbert-Schmidt distance between a given state and the set of separable states. While Hilbert-Schmidt distance does not form a proper entanglement measure, it can nevertheless be useful for witnessing entanglement. We provide a few methods based on the Gilbert's algorithm that can reliably qualify a given state as strongly entangled or practically separable, while being computationally efficient. The method also outputs successively improved approximations to the closest separable state for the given state. We demonstrate the efficacy of the method with examples.